Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disabled custom ids feature #20

Merged
merged 1 commit into from
Nov 2, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,7 @@ local.properties
### m2e ###
.classpath
.project


### jvm (https://github.com/caarlos0/jvm) ###
.java-version
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import org.apache.tinkerpop.gremlin.structure.Graph.Features;
import org.apache.tinkerpop.gremlin.structure.Graph.Features.VertexFeatures;
import org.apache.tinkerpop.gremlin.structure.Graph.Features.VertexPropertyFeatures;
import org.apache.tinkerpop.gremlin.structure.util.StringFactory;

public class ODBFeatures {
Expand Down Expand Up @@ -70,6 +71,12 @@ public boolean supportsMetaProperties() {
return false;
}

@Override
public VertexPropertyFeatures properties()
{
return OrientVertexPropertyFeatures.INSTANCE;
}

}

public static class OrientEdgeFeatures extends OrientElementFeatures implements Features.EdgeFeatures {
Expand Down Expand Up @@ -114,4 +121,46 @@ public boolean supportsThreadedTransactions() {
}

}

public static class OrientVertexPropertyFeatures implements Features.VertexPropertyFeatures {

static final OrientVertexPropertyFeatures INSTANCE = new OrientVertexPropertyFeatures();

@Override
public boolean supportsAnyIds() {
return false;
}

@Override
public boolean supportsCustomIds() {
return false;
}

@Override
public boolean supportsNumericIds() {
return false;
}

@Override
public boolean supportsStringIds() {
return false;
}

@Override
public boolean supportsUserSuppliedIds() {
return false;
}

@Override
public boolean supportsUuidIds() {
return false;
}

@Override
public boolean willAllowId(Object id) {
return false;
}

}

}