Class RegexPathParam


  • @Path("/PathParamWithRegex")
    public class RegexPathParam
    extends java.lang.Object
    Sample microservice demonstrating path parameters with regex constraints.
    • Constructor Summary

      Constructors 
      Constructor Description
      RegexPathParam()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      javax.ws.rs.core.Response createEndpoint​(java.lang.String assetType, java.lang.String id)  
      javax.ws.rs.core.Response getAssetState​(java.lang.String assetType, java.lang.String id)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RegexPathParam

        public RegexPathParam()
    • Method Detail

      • getAssetState

        @GET
        @Path("{assetType : [a-zA-Z][a-zA-Z_0-9]*}/{id}/states")
        public javax.ws.rs.core.Response getAssetState​(@PathParam("assetType")
                                                       java.lang.String assetType,
                                                       @PathParam("id")
                                                       java.lang.String id)
      • createEndpoint

        @GET
        @Path("/endpoints/{assetType : [a-zA-Z][a-zA-Z_0-9]*}/{id}")
        public javax.ws.rs.core.Response createEndpoint​(@PathParam("assetType")
                                                        java.lang.String assetType,
                                                        @PathParam("id")
                                                        java.lang.String id)