Class MetadataResource


  • @Produces("application/json")
    @Consumes("application/json")
    @Path("/{version : v\\d\\.\\d|latest}/{context}/metadata-catalog/")
    public class MetadataResource
    extends AbstractResource
    JPARS 2.0 metadata catalog. Resource metadata and schemas.
    Author:
    Dmitry Kornilov
    Since:
    EclipseLink 2.6.0.
    • Constructor Detail

      • MetadataResource

        public MetadataResource()
    • Method Detail

      • getMetadataCatalog

        @GET
        public javax.ws.rs.core.Response getMetadataCatalog​(@PathParam("version")
                                                            java.lang.String version,
                                                            @PathParam("context")
                                                            java.lang.String persistenceUnit,
                                                            @Context
                                                            javax.ws.rs.core.HttpHeaders httpHeaders,
                                                            @Context
                                                            javax.ws.rs.core.UriInfo uriInfo)
        Returns metadata catalog.
      • getEntityResource

        @GET
        @Produces({"application/json","application/schema+json"})
        @Consumes({"application/json","application/schema+json"})
        @Path("entity/{entityName}")
        public javax.ws.rs.core.Response getEntityResource​(@PathParam("version")
                                                           java.lang.String version,
                                                           @PathParam("context")
                                                           java.lang.String persistenceUnit,
                                                           @PathParam("entityName")
                                                           java.lang.String entityName,
                                                           @Context
                                                           javax.ws.rs.core.HttpHeaders httpHeaders,
                                                           @Context
                                                           javax.ws.rs.core.UriInfo uriInfo)
        Returns entity metadata if accepted media type is 'application/json' or entity schema if accepted media type is 'application/schema+json'.
      • getQueryResource

        @GET
        @Produces({"application/json","application/schema+json"})
        @Consumes({"application/json","application/schema+json"})
        @Path("query/{queryName}")
        public javax.ws.rs.core.Response getQueryResource​(@PathParam("version")
                                                          java.lang.String version,
                                                          @PathParam("context")
                                                          java.lang.String persistenceUnit,
                                                          @PathParam("queryName")
                                                          java.lang.String queryName,
                                                          @Context
                                                          javax.ws.rs.core.HttpHeaders httpHeaders,
                                                          @Context
                                                          javax.ws.rs.core.UriInfo uriInfo)
        Returns query metadata if accepted media type is 'application/json' or entity schema if accepted media type is 'application/schema+json'.