@Override public TitanLabel getEdgeLabel(String name) { TitanType et = getType(name); if (et == null) { return config.getAutoEdgeTypeMaker().makeLabel(name, makeType()); } else if (et.isEdgeLabel()) { return (TitanLabel) et; } else throw new IllegalArgumentException("The type of given name is not a label: " + name); }
@Override public TitanKey getPropertyKey(String name) { TitanType et = getType(name); if (et == null) { return config.getAutoEdgeTypeMaker().makeKey(name, makeType()); } else if (et.isPropertyKey()) { return (TitanKey) et; } else throw new IllegalArgumentException("The type of given name is not a key: " + name); }