primaryKey
primaryKey flag set to the given value.- Parameters:
field- The original fieldprimaryKey- The value for the primaryKey flag- Returns:
- a new field with the unique flag set to the specified value
static RecordTokenTypestatic Fieldstatic RecordTokenTypeannotate(RecordTokenType type,
String propertyName,
String propertyValue) static RecordTokenTypederiveSchema(ScalarTyped... columns) static TokenTypeTokenType.getDomainValuesAsStrings(FieldDomain domain) static <T extends ScalarTyped & Named>
RecordTokenTypegetRecordType(T... fields) static ScalarTokenType[]getTypes(RecordTokenType type) static booleanstatic booleanhasDomainValues(RecordTokenType type,
String field) static RecordTokenTypehomogeneousRecord(int size,
ScalarTokenType fieldType,
String fieldBase) static final RecordTokenTypematchFieldNames(RecordTokenType source,
RecordTokenType match) static RecordTokenTypemerge(RecordTokenType... types) static FieldDomainmergeDomain(FieldDomain domain1,
FieldDomain domain2) static DataRepresentationmergeRepresentations(TokenType... types) static RecordTokenTypemergeTypes(TokenType... types) static RecordTokenTypemutating(RecordTokenType type,
Collection<String> modifiedFields) static FieldprimaryKey flag set to falsestatic RecordTokenTypenonUnique(RecordTokenType type) primaryKey
flags set to falsestatic RecordTokenTypeoverlay(RecordTokenType... types) static FieldprimaryKey(Field field,
boolean primaryKey) primaryKey flag set to the given value.static final RecordTokenTyperemove(RecordTokenType source,
String... removed) static final RecordTokenTyperemove(RecordTokenType source,
List<String> removed) static final RecordTokenTyperename(RecordTokenType source,
String[] sourceNames,
String[] targetNames) static final RecordTokenTyperename(RecordTokenType source,
Map<String,String> sourceToTargetNameMap) static final RecordTokenTypereorderAndRename(RecordTokenType source,
String[] sourceNames,
String[] targetNames) static final RecordTokenTyperetain(RecordTokenType source,
String... retained) static final RecordTokenTyperetain(RecordTokenType source,
List<String> retained) static final RecordTokenTypeselect(RecordTokenType source,
String... selected) static final RecordTokenTypeselect(RecordTokenType source,
List<String> selected) static RecordTokenTypestrictOverlay(boolean dropUnique,
RecordTokenType... types) isAssignableFrom() is true for the types.static Stringstatic final RecordTokenTypetoType(DataRepresentation representation,
Namespace<ScalarTokenType> namespace) static final RecordTokenTypevalidateFieldSelection(String propertyName,
RecordTokenType source,
String... selected) static final voidvalidateRequiredFields(String propertyName,
RecordTokenType source,
RecordTokenType required) static ScalarTokenTypestatic RecordTokenTypewidestNamedType(RecordTokenType... types) isAssignableFrom()
is true for all of the specified types matched by name.static RecordTokenTypewidestType(RecordTokenType... types) isAssignableFrom()
is true for all of the specified types.static ScalarTokenTypewidestType(ScalarTokenType... types) static RecordTokenTypewithDomainValues(RecordTokenType type,
String fieldName,
Set<String> discovered) static RecordTokenTypewrap(String name,
ScalarTokenType type) static RecordTokenTypewrap(String prefix,
List<? extends ScalarTokenType> types) static RecordTokenTypewrap(List<? extends ScalarTokenType> types) fields - the objects representing the fields of the compositepropertyName - the property name to use in the validation failure exceptionsource - the record type to checkselected - the field names to validate, in the desired ordering
for the new typecom.pervasive.datarush.graphs.physical.InvalidPropertyValueException - if one or more of the specified fields do not
exist in the source typepropertyName - the property name to use in the validation failure exceptionsource - the record type to checkrequired - the fields to validatecom.pervasive.datarush.graphs.physical.InvalidPropertyValueException - if one or more of the specified fields do not
exist in the source typeThe specified fields must be valid names in the source type.
source - the record type to filterselected - the field names to keep in the new type, in the desired ordering
for the new typeInvalidFieldException - if one or more of the specified fields do not
exist in the source typerepresentation - the representationnamespace - the list of fieldsThe specified fields must be valid names in the source type.
source - the record type to filterselected - the field names to keep in the new type, in the desired ordering
for the new typeInvalidFieldException - if one or more of the specified fields do not
exist in the source typeThe specified fields do not need to be valid names in the source type.
source - the record type to filterretained - the field names to keep in the new typeThe specified fields do not need to be valid names in the source type.
source - the record type to filterretained - the field names to keep in the new typeThe specified fields do not need to be valid names in the source type.
source - the record type to filterremoved - the field names to remove from the new typeThe specified fields do not need to be valid names in the source type.
source - the record type to filterremoved - the field names to remove from the new typesourceNames. Those fields are then renamed to the
corresponding ordinal counterpart in targetNames.source - source record typesourceNames - list of fields in source ordered to the
desired outputtargetNames - list of names the corresponding ordinal source field
name will be changed tosource - source token typesourceToTargetNameMap - mapping from old names to new namessource - source token typesourceNames - list of field names in the sourcetargetNames - list of names to substitute for the source namesname - the name for the fieldtype - the type of the field dataprefix + i,
where i is the field's 0-based position in the input list.prefix - the field name prefixtypes - the types of field data"field" + i,
where i is the flow's 0-based position in the input list.types - the types of field datatypes - List of typesThe following conditions will hold with respect to the ordering of fields in the result:
For a destructive merge which overwrites fields in collision, use
overlay(RecordTokenType...) instead.
types - the record types to mergeThe following conditions will hold with respect to the ordering of fields in the result:
For a non-destructive merge which doesn't replace collisions, use
merge(RecordTokenType...) instead.
types - the record types to mergeisAssignableFrom() is true for the types. Otherwise null
will be returned.
The following conditions will hold with respect to the ordering of fields in the result:
For a non-destructive merge which doesn't replace collisions, use
merge(RecordTokenType...) instead.
dropUnique - if true will not include fields not present in all recordstypes - the record types to mergeInvalidFieldException
The result is equivalent to calling merge(RecordTokenType...),
passing each record type straight through and replacing all scalar flows in
the input with wrap("input"+i, type). Refer to merge(RecordTokenType...)
for specific details on the merged result.
types - the types to mergesource but the field names of match.source - source record typematch - record type whose field names should be matchedfieldBase + index where
index is the field's index in the record type.size - Number of desired fieldsfieldType - Scalar type of all fieldsfieldBase - Base field nameTokenType.
This method acts as an inverse to the method {toJSON(TokenType)
method on token types; for any type, it will always be
the case that:
type.equals(TypeUtil.fromJSON(TypeUtil.toJSON(type))
json - the JSON format of a type.type - the type for which to generate a descriptionT for which T.isAssignableFrom()
is true for all of the types.types - the scalar types to analyzenull.type - the record typetype - the type to getisAssignableFrom()
is true for all of the specified types. Such a type can only
be found if all record types contain the same number of fields
and a widest scalar type can be found for each field.types - the record types to analyzenull.isAssignableFrom()
is true for all of the specified types matched by name. Such a
type can only be found if all record types contain the same number
of named fields and a widest scalar type can be found for each named field.types - the record types to analyzenull.field - The field to annotatepropertyName - The name of the annotationpropertyValue - The value of the annotationprimaryKey flag set to the given value.field - The original fieldprimaryKey - The value for the primaryKey flagprimaryKey flag set to falsefield - The original fieldprimaryKey
flags set to falsetype - the original typetype - The type to annotatepropertyName - The name of the annotationpropertyValue - The value of the annotationcolumns - objects describing the columns. These objects implicitly
provide the column data type.type - the original source type to be extended with source informationThis methods assumes that both the underlying schema and the relative ordering of records in the flow is unchanged.
the - the original typemodifiedFields - the fields that may be modifieddomain - the domaintype - the typefield - the name of the fieldInvalidFieldException - if the field is not definedtype - the typeInvalidFieldException - if the field is not definedtype - the original typefieldName - the field to updatediscovered - the discovered valueslowerBound equal to the min of the two lower bounds or
unspecified lower bound if either is unspecifiedupperBound equal to the max of the two upper bounds or
unspecified upper bound if either is unspecifiedvalues equal to the union of the two sets of values
or unspecified if either is unspecifieddomain1 - the first domaindomain2 - the second domainIllegalArgumentException - if there is no common base class between the types of the two domains