private void checkPrimaryKeys() { E.checkArgument(this.idStrategy == IdStrategy.DEFAULT || this.idStrategy == IdStrategy.PRIMARY_KEY, "Not allowed to use id strategy '%s' and assign " + "primary keys at the same time for vertex label '%s'", this.idStrategy, this.name); E.checkArgument(!this.properties.isEmpty(), "The properties of vertex label '%s' " + "can't be empty when id strategy is '%s'", this.name, IdStrategy.PRIMARY_KEY); E.checkNotEmpty(this.primaryKeys, "primary keys", this.name); // Use loop instead containAll for more detailed exception info. for (String key : this.primaryKeys) { E.checkArgument(this.properties.contains(key), "The primary key '%s' of vertex label '%s' " + "must be contained in properties: %s", key, this.name, this.properties); } }
private void checkFields(Set<Id> propertyIds) { List<String> fields = this.indexFields; E.checkNotEmpty(fields, "index fields", this.name);
private void checkPrimaryKeys() { E.checkArgument(this.idStrategy == IdStrategy.DEFAULT || this.idStrategy == IdStrategy.PRIMARY_KEY, "Not allowed to use id strategy '%s' and assign " + "primary keys at the same time for vertex label '%s'", this.idStrategy, this.name); E.checkArgument(!this.properties.isEmpty(), "The properties of vertex label '%s' " + "can't be empty when id strategy is '%s'", this.name, IdStrategy.PRIMARY_KEY); E.checkNotEmpty(this.primaryKeys, "primary keys", this.name); // Use loop instead containAll for more detailed exception info. for (String key : this.primaryKeys) { E.checkArgument(this.properties.contains(key), "The primary key '%s' of vertex label '%s' " + "must be contained in properties: %s", key, this.name, this.properties); } }
private void checkFields(Set<Id> propertyIds) { List<String> fields = this.indexFields; E.checkNotEmpty(fields, "index fields", this.name);