Class PetriNetController


  • @RestController
    @RequestMapping("/api/petrinet")
    @ConditionalOnProperty(value="nae.petrinet.web.enabled",
                           havingValue="true",
                           matchIfMissing=true)
    public class PetriNetController
    extends java.lang.Object
    • Constructor Detail

      • PetriNetController

        public PetriNetController()
    • Method Detail

      • getAll

        @GetMapping(produces="application/hal+json")
        public PetriNetReferenceResources getAll​(@RequestParam(value="indentifier",required=false)
                                                 java.lang.String identifier,
                                                 @RequestParam(value="version",required=false)
                                                 java.lang.String version,
                                                 org.springframework.security.core.Authentication auth,
                                                 java.util.Locale locale)
      • getOne

        @GetMapping(value="/{id}",
                    produces="application/hal+json")
        public PetriNetReferenceResource getOne​(@PathVariable("id")
                                                java.lang.String id,
                                                org.springframework.security.core.Authentication auth,
                                                java.util.Locale locale)
      • getOne

        @GetMapping(value="/{identifier}/{version}",
                    produces="application/hal+json")
        public PetriNetReferenceResource getOne​(@PathVariable("identifier")
                                                java.lang.String identifier,
                                                @PathVariable("version")
                                                java.lang.String version,
                                                org.springframework.security.core.Authentication auth,
                                                java.util.Locale locale)
      • getTransitionReferences

        @GetMapping(value="/transitions",
                    produces="application/hal+json")
        public TransitionReferencesResource getTransitionReferences​(@RequestParam
                                                                    java.util.List<java.lang.String> ids,
                                                                    org.springframework.security.core.Authentication auth,
                                                                    java.util.Locale locale)
      • getDataFieldReferences

        @PostMapping(value="/data",
                     consumes="application/json",
                     produces="application/hal+json")
        public DataFieldReferencesResource getDataFieldReferences​(@RequestBody
                                                                  java.util.List<TransitionReference> referenceBody,
                                                                  java.util.Locale locale)
      • getRoles

        @GetMapping(value="/{netId}/roles",
                    produces="application/hal+json")
        public ProcessRolesResource getRoles​(@PathVariable("netId")
                                             java.lang.String netId,
                                             java.util.Locale locale)
      • getTransactions

        @GetMapping(value="/{netId}/transactions",
                    produces="application/hal+json")
        public TransactionsResource getTransactions​(@PathVariable("netId")
                                                    java.lang.String netId,
                                                    java.util.Locale locale)
      • getNetFile

        @PreAuthorize("@authorizationService.hasAuthority(\'ADMIN\')")
        @GetMapping(value="/{netId}/file",
                    produces="application/octet-stream")
        public org.springframework.core.io.FileSystemResource getNetFile​(@PathVariable("netId")
                                                                         java.lang.String netId,
                                                                         @RequestParam(value="title",required=false)
                                                                         java.lang.String title,
                                                                         org.springframework.security.core.Authentication auth,
                                                                         javax.servlet.http.HttpServletResponse response)
      • searchPetriNets

        @PostMapping(value="/search",
                     produces="application/hal+json")
        @ResponseBody
        public org.springframework.hateoas.PagedModel<PetriNetReferenceResource> searchPetriNets​(@RequestBody
                                                                                                 java.util.Map<java.lang.String,​java.lang.Object> criteria,
                                                                                                 org.springframework.security.core.Authentication auth,
                                                                                                 org.springframework.data.domain.Pageable pageable,
                                                                                                 org.springframework.data.web.PagedResourcesAssembler<PetriNetReference> assembler,
                                                                                                 java.util.Locale locale)
      • deletePetriNet

        @PreAuthorize("@petriNetAuthorizationService.canCallProcessDelete(#auth.getPrincipal(), #processId)")
        @DeleteMapping(value="/{id}",
                       produces="application/hal+json")
        public MessageResource deletePetriNet​(@PathVariable("id")
                                              java.lang.String processId,
                                              org.springframework.security.core.Authentication auth)
      • getOne

        @GetMapping(value="/case/{id}",
                    produces="application/hal+json")
        public PetriNetImportReference getOne​(@PathVariable("id")
                                              java.lang.String caseId)
      • decodeUrl

        public static java.lang.String decodeUrl​(java.lang.String s1)