Java Code Examples for com.orientechnologies.orient.core.index.OIndex#getName()
The following examples show how to use
com.orientechnologies.orient.core.index.OIndex#getName() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: OIndexModel.java From wicket-orientdb with Apache License 2.0 | 5 votes |
@Override protected void handleObject(OIndex<?> object) { indexName = object.getName(); OIndexDefinition indexDefinition = object.getDefinition(); if(indexDefinition!=null) { String className = indexDefinition.getClassName(); if(className!=null) classModel = new OClassModel(className); } }
Example 2
Source File: OIndexPrototyper.java From wicket-orientdb with Apache License 2.0 | 5 votes |
@Override protected OIndex<?> createInstance(OIndex proxy) { OSchema schema = OrientDbWebSession.get().getDatabase().getMetadata().getSchema(); OClass oClass = schema.getClass(proxy.getDefinition().getClassName()); String name = proxy.getName(); List<String> fields = proxy.getDefinition().getFields(); String type = proxy.getType(); if(name==null) name=oClass.getName()+"."+fields.get(0); ODocument metadata = proxy.getMetadata(); String algorithm = proxy.getAlgorithm(); values.keySet().retainAll(RW_ATTRS); return oClass.createIndex(name, type, null, metadata, algorithm, fields.toArray(new String[0])); }
Example 3
Source File: OIndexNameConverter.java From wicket-orientdb with Apache License 2.0 | 4 votes |
@Override public String convertToString(OIndex<?> value, Locale locale) { return value.getName(); }