本文整理汇总了Java中com.redhat.lightblue.util.Error.reset方法的典型用法代码示例。如果您正苦于以下问题:Java Error.reset方法的具体用法?Java Error.reset怎么用?Java Error.reset使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.redhat.lightblue.util.Error
的用法示例。
在下文中一共展示了Error.reset方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: simpleExplain
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@GET
@LZF
@Path("/explain/{entity}/{version}")
//?Q&P&S&from&to
public Response simpleExplain(@PathParam(PARAM_ENTITY) String entity,
@PathParam(PARAM_VERSION) String version,
@QueryParam("Q") String q,
@QueryParam("P") String p,
@QueryParam("S") String s,
@QueryParam("from") Long from,
@QueryParam("to") Long to,
@QueryParam("maxResults") Long maxResults) throws IOException {
Error.reset();
String request=buildSimpleRequest(entity,version,q,p,s,from,to,maxResults).toString();
CallStatus st = new ExplainCommand(null, entity, version, request, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例2: createSchema
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@PUT
@LZF
@Path("/{entity}/schema={version}")
@Consumes(MediaType.APPLICATION_JSON)
public String createSchema(@Context SecurityContext sc, @PathParam(PARAM_ENTITY) String entity, @PathParam(PARAM_VERSION) String version, String schema) {
Error.reset();
checkPermission(sc, MetadataRole.INSERT_SCHEMA);
return new CreateEntitySchemaCommand(entity, version, schema).run();
}
示例3: clearDefaultVersion
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@DELETE
@LZF
@Path("/{entity}/default")
public String clearDefaultVersion(@Context SecurityContext sc, @PathParam(PARAM_ENTITY) String entity) {
Error.reset();
checkPermission(sc, MetadataRole.UPDATE_DEFAULTVERSION);
return new SetDefaultVersionCommand(entity, null).run();
}
示例4: lock
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@POST
@Path("/lock/")
public Response lock(String request) {
Error.reset();
CallStatus st = getLockCommand(request, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例5: getEntityVersions
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@GET
@LZF
@Path("/{entity}")
public String getEntityVersions(@Context SecurityContext sc, @PathParam(PARAM_ENTITY) String entity) {
Error.reset();
checkPermission(sc, MetadataRole.FIND_ENTITY_VERSIONS);
return new GetEntityVersionsCommand(entity).run();
}
示例6: release
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@DELETE
@Path("/lock/{domain}/{callerId}/{resourceId}")
public Response release(@PathParam("domain") String domain,
@PathParam("callerId") String callerId,
@PathParam("resourceId") String resourceId) {
Error.reset();
CallStatus st = new ReleaseCommand(domain, callerId, resourceId, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例7: getLockCount
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@GET
@Path("/lock/{domain}/{callerId}/{resourceId}")
public Response getLockCount(@PathParam("domain") String domain,
@PathParam("callerId") String callerId,
@PathParam("resourceId") String resourceId) {
Error.reset();
CallStatus st = new GetLockCountCommand(domain, callerId, resourceId, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例8: ping
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@PUT
@Path("/lock/{domain}/{callerId}/{resourceId}/ping")
public Response ping(@PathParam("domain") String domain,
@PathParam("callerId") String callerId,
@PathParam("resourceId") String resourceId) {
Error.reset();
CallStatus st = new LockPingCommand(domain, callerId, resourceId, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例9: getEntityNames
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@GET
@LZF
@Path("/s={statuses}")
public String getEntityNames(@Context SecurityContext sc, @PathParam("statuses") String statuses) {
StringTokenizer tok = new StringTokenizer(" ,;:.");
String[] s = new String[tok.countTokens()];
int i = 0;
while (tok.hasMoreTokens()) {
s[i++] = tok.nextToken();
}
Error.reset();
checkPermission(sc, MetadataRole.FIND_ENTITY_NAMES);
return new GetEntityNamesCommand(s).run();
}
示例10: save
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@POST
@LZF
@Path("/save/{entity}/{version}")
public Response save(@PathParam(PARAM_ENTITY) String entity,
@PathParam(PARAM_VERSION) String version,
String request) {
Error.reset();
CallStatus st = new SaveCommand(entity, version, request, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例11: update
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@POST
@LZF
@Path("/update/{entity}/{version}")
public Response update(@PathParam(PARAM_ENTITY) String entity,
@PathParam(PARAM_VERSION) String version,
String request) {
Error.reset();
CallStatus st = new UpdateCommand(entity, version, request, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例12: delete
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@POST
@LZF
@Path("/delete/{entity}/{version}")
public Response delete(@PathParam(PARAM_ENTITY) String entity,
@PathParam(PARAM_VERSION) String version,
String req) {
Error.reset();
CallStatus st = new DeleteCommand(entity, version, req, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例13: getMetadata
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@GET
@LZF
@Path("/{entity}/{version}")
public String getMetadata(@Context SecurityContext sc, @PathParam(PARAM_ENTITY) String entity, @PathParam(PARAM_VERSION) String version) {
Error.reset();
checkPermission(sc, MetadataRole.FIND_ENTITY_METADATA);
return new GetEntityMetadataCommand(entity, version).run();
}
示例14: explain
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@POST
@LZF
@Path("/explain/{entity}/{version}")
public Response explain(@PathParam(PARAM_ENTITY) String entity,
@PathParam(PARAM_VERSION) String version,
String request) {
Error.reset();
CallStatus st = new ExplainCommand(entity, version, request, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}
示例15: bulk
import com.redhat.lightblue.util.Error; //导入方法依赖的package包/类
@POST
@LZF
@Path("/bulk")
public Response bulk(String request) {
Error.reset();
CallStatus st = new BulkRequestCommand(request, METRICS).run();
return Response.status(st.getHttpStatus()).entity(st.toString()).build();
}