Search in sources :

Example 6 with FieldParent

use of org.collectionspace.chain.csp.schema.FieldParent in project application by collectionspace.

the class ServiceBindingsGeneration method isScalarRepeat.

/*
	 * Repeatable scalars (multivalued scalars)...
	 */
private boolean isScalarRepeat(FieldSet fieldSet) {
    boolean result = false;
    FieldParent parent = fieldSet.getParent();
    if (parent instanceof Repeat) {
        Repeat repeat = (Repeat) parent;
        if (repeat.isTrueRepeatField() == true) {
            String[] parts = repeat.getfullID().split("/");
            if (parts.length == 1) {
                result = true;
            }
        }
    }
    return result;
}
Also used : FieldParent(org.collectionspace.chain.csp.schema.FieldParent) Repeat(org.collectionspace.chain.csp.schema.Repeat)

Aggregations

FieldParent (org.collectionspace.chain.csp.schema.FieldParent)6 Repeat (org.collectionspace.chain.csp.schema.Repeat)6 FieldSet (org.collectionspace.chain.csp.schema.FieldSet)4 Group (org.collectionspace.chain.csp.schema.Group)2 Record (org.collectionspace.chain.csp.schema.Record)2