Codota Logo
ValueDataUtil.sum
Code IndexAdd Codota to your IDE (free)

How to use
sum
method
in
org.pentaho.di.core.row.ValueDataUtil

Best Java code snippets using org.pentaho.di.core.row.ValueDataUtil.sum (Showing top 5 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
LocalDateTime l =
  • Codota Iconnew LocalDateTime()
  • Codota IconLocalDateTime.now()
  • Codota IconDateTimeFormatter formatter;String text;formatter.parseLocalDateTime(text)
  • Smart code suggestions by Codota
}
origin: pentaho/pentaho-kettle

@Test
public void testSumWithNullValues() throws Exception {
 ValueMetaInterface metaA = new ValueMetaInteger();
 metaA.setStorageType( ValueMetaInterface.STORAGE_TYPE_NORMAL );
 ValueMetaInterface metaB = new ValueMetaInteger();
 metaA.setStorageType( ValueMetaInterface.STORAGE_TYPE_NORMAL );
 assertNull( ValueDataUtil.sum( metaA, null, metaB, null ) );
 Long valueB = new Long( 2 );
 ValueDataUtil.sum( metaA, null, metaB, valueB );
}
origin: pentaho/pentaho-kettle

 aggregate.agg[i] = ValueDataUtil.sum( valueMeta, value, subjMeta, subj );
 break;
case MemoryGroupByMeta.TYPE_GROUP_AVERAGE:
 if ( !subjMeta.isNull( subj ) ) {
  aggregate.agg[i] = ValueDataUtil.sum( valueMeta, value, subjMeta, subj );
  aggregate.counts[i]++;
origin: pentaho/pentaho-kettle

 data.agg[ i ] = ValueDataUtil.sum( valueMeta, value, subjMeta, subj );
 break;
case GroupByMeta.TYPE_GROUP_AVERAGE:
 if ( !subjMeta.isNull( subj ) ) {
  data.agg[ i ] = ValueDataUtil.sum( valueMeta, value, subjMeta, subj );
  data.counts[ i ]++;
origin: pentaho/pentaho-kettle

@Test
public void testSumConvertingStorageTypeToNormal() throws Exception {
 ValueMetaInterface metaA = mock( ValueMetaInteger.class );
 metaA.setStorageType( ValueMetaInterface.STORAGE_TYPE_BINARY_STRING );
 ValueMetaInterface metaB = new ValueMetaInteger();
 metaB.setStorageType( ValueMetaInterface.STORAGE_TYPE_BINARY_STRING );
 Object valueB = "2";
 when( metaA.convertData( metaB, valueB ) ).thenAnswer( new Answer<Long>() {
  @Override
  public Long answer( InvocationOnMock invocation ) throws Throwable {
   return new Long( 2 );
  }
 } );
 Object returnValue = ValueDataUtil.sum( metaA, null, metaB, valueB );
 verify( metaA ).convertData( metaB, valueB );
 assertEquals( 2L, returnValue );
 assertEquals( metaA.getStorageType(), ValueMetaInterface.STORAGE_TYPE_NORMAL );
}
origin: pentaho/pentaho-kettle

targetData = targetMeta.convertData( sourceMeta, sourceData );
if ( prevTargetData != null ) {
 prevTargetData = ValueDataUtil.sum( targetMeta, prevTargetData, targetMeta, targetData );
} else {
 prevTargetData = targetData;
org.pentaho.di.core.rowValueDataUtilsum

Popular methods of ValueDataUtil

  • checksumAdler32
  • checksumCRC32
  • createChecksum
  • getFileEncoding
    Get file encoding.
  • isXMLFileWellFormed
    Checks an xml file is well formed.
  • loadFileContentInBinary
  • plus
  • round
    Rounding with decimal places with a given rounding method
  • DateDiff
    Returns the number of days that have elapsed between dataA and dataB.
  • DateWorkingDiff
  • combination1
    A + B * C
  • combination2
    SQRT( A*A + B*B )
  • combination1,
  • combination2,
  • divide,
  • divideBigDecimals,
  • getJaroWinkler_Similitude,
  • getJaro_Similitude,
  • isSpace,
  • minus,
  • multiply,
  • multiplyBigDecimals

Popular in Java

  • Making http requests using okhttp
  • getResourceAsStream (ClassLoader)
  • notifyDataSetChanged (ArrayAdapter)
  • runOnUiThread (Activity)
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • CountDownLatch (java.util.concurrent)
    A synchronization aid that allows one or more threads to wait until a set of operations being perfor
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • HttpServletRequest (javax.servlet.http)
    Extends the javax.servlet.ServletRequest interface to provide request information for HTTP servlets.
  • Join (org.hibernate.mapping)
  • Reflections (org.reflections)
    Reflections one-stop-shop objectReflections scans your classpath, indexes the metadata, allows you t
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now