本文整理了Java中cascading.util.Util.split()
方法的一些代码示例,展示了Util.split()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Util.split()
方法的具体详情如下:
包路径:cascading.util.Util
类名称:Util
方法名:split
暂无
代码示例来源:origin: cwensel/cascading
public static <T> List<T> split( Class<T> type, String values )
{
return split( type, ",", values );
}
代码示例来源:origin: cwensel/cascading
public List<Integer> getOrdinals()
{
if( ordinals == null )
ordinals = Util.split( Integer.class, ",", getConf().get( "cascading.node.ordinals" ) );
return ordinals;
}
代码示例来源:origin: cascading/cascading-hadoop2-io
public List<Integer> getOrdinals()
{
if( ordinals == null )
ordinals = Util.split( Integer.class, ",", getConf().get( "cascading.node.ordinals" ) );
return ordinals;
}
代码示例来源:origin: cascading/cascading-hadoop2-tez
/**
* Maps each input to an ordinal on the flowelement. an input may be bound to multiple ordinals.
*
* @param element
*/
private SortedListMultiMap<Integer, LogicalInput> createInputMap( FlowElement element )
{
String id = FlowElements.id( element );
SortedListMultiMap<Integer, LogicalInput> ordinalMap = new SortedListMultiMap<>();
for( LogicalInput logicalInput : inputMap.values() )
{
Configuration configuration = inputConfigMap.get( logicalInput );
String foundID = configuration.get( "cascading.node.source" );
if( Util.isEmpty( foundID ) )
throw new IllegalStateException( "cascading.node.source property not set on source LogicalInput" );
if( !foundID.equals( id ) )
continue;
String values = configuration.get( "cascading.node.ordinals", "" );
List<Integer> ordinals = Util.split( Integer.class, ",", values );
for( Integer ordinal : ordinals )
ordinalMap.put( ordinal, logicalInput );
}
return ordinalMap;
}
代码示例来源:origin: cwensel/cascading
/**
* Maps each input to an ordinal on the flowelement. an input may be bound to multiple ordinals.
*
* @param element
*/
private SortedListMultiMap<Integer, LogicalInput> createInputMap( FlowElement element )
{
String id = FlowElements.id( element );
SortedListMultiMap<Integer, LogicalInput> ordinalMap = new SortedListMultiMap<>();
for( LogicalInput logicalInput : inputMap.values() )
{
Configuration configuration = inputConfigMap.get( logicalInput );
String foundID = configuration.get( "cascading.node.source" );
if( Util.isEmpty( foundID ) )
throw new IllegalStateException( "cascading.node.source property not set on source LogicalInput" );
if( !foundID.equals( id ) )
continue;
String values = configuration.get( "cascading.node.ordinals", "" );
List<Integer> ordinals = Util.split( Integer.class, ",", values );
for( Integer ordinal : ordinals )
ordinalMap.put( ordinal, logicalInput );
}
return ordinalMap;
}
内容来源于网络,如有侵权,请联系作者删除!