org.op4j.operators.qualities
Interface CastableToStructuresOperator

All Known Subinterfaces:
ILevel0GenericUniqOperator<I,T>
All Known Implementing Classes:
Level0GenericUniqOperator, Level0GenericUniqOperator

public interface CastableToStructuresOperator

This interface contains methods for casts to structures: array, lists, maps and sets.

Since:
1.0
Author:
Daniel Fernández

Method Summary
<X> Operator
castToArrayOf(org.javaruntype.type.Type<X> type)
           Casts the operator's target as an array of the specified type.
<X> Operator
castToListOf(org.javaruntype.type.Type<X> type)
           Casts the operator's target as a list of the specified type.
<K,V> Operator
castToMapOf(org.javaruntype.type.Type<K> keyType, org.javaruntype.type.Type<V> valueType)
           Casts the operator's target as a map of the specified types.
<X> Operator
castToSetOf(org.javaruntype.type.Type<X> type)
           Casts the operator's target as a set of the specified type.
 

Method Detail

castToArrayOf

<X> Operator castToArrayOf(org.javaruntype.type.Type<X> type)

Casts the operator's target as an array of the specified type.

Type Parameters:
X - the type of the elements of the array
Parameters:
type - the type of the elements of the array
Returns:
the resulting casted operator

castToListOf

<X> Operator castToListOf(org.javaruntype.type.Type<X> type)

Casts the operator's target as a list of the specified type.

Type Parameters:
X - the type of the elements of the list
Parameters:
type - the type of the elements of the list
Returns:
the resulting casted operator

castToMapOf

<K,V> Operator castToMapOf(org.javaruntype.type.Type<K> keyType,
                           org.javaruntype.type.Type<V> valueType)

Casts the operator's target as a map of the specified types.

Type Parameters:
K - the type for the map's keys
V - the type for the map's values
Parameters:
keyType - the type for the map's keys
valueType - the type for the map's values
Returns:
the resulting map

castToSetOf

<X> Operator castToSetOf(org.javaruntype.type.Type<X> type)

Casts the operator's target as a set of the specified type.

Type Parameters:
X - the type of the elements of the set
Parameters:
type - the type of the elements of the set
Returns:
the resulting casted operator


Copyright © 2012 The OP4J team. All Rights Reserved.