Class SystemPropertiesCliResource

    • Field Detail

      • injector

        @Context
        protected org.glassfish.hk2.api.ServiceLocator injector
      • entity

        protected Dom entity
      • domain

        protected Domain domain
    • Constructor Detail

      • SystemPropertiesCliResource

        public SystemPropertiesCliResource()
    • Method Detail

      • setEntity

        public void setEntity​(Dom p)
      • getEntity

        public Dom getEntity()
      • create

        @POST
        public jakarta.ws.rs.core.Response create​(Map<String,​String> data)
      • update

        @PUT
        public jakarta.ws.rs.core.Response update​(Map<String,​String> data)
      • getSystemPropertyResource

        @Path("{Name}/")
        @POST
        public jakarta.ws.rs.core.Response getSystemPropertyResource​(@PathParam("Name")
                                                                     String id,
                                                                     Map<String,​String> data)
      • deleteSystemProperty

        @Path("{Name}/")
        @DELETE
        public jakarta.ws.rs.core.Response deleteSystemProperty​(@PathParam("Name")
                                                                String id,
                                                                HashMap<String,​String> data)
      • getSystemProperties

        protected void getSystemProperties​(Map<String,​Map<String,​String>> properties,
                                           Dom dom,
                                           boolean getDefaults)
      • getCluster

        protected Dom getCluster​(Dom domain,
                                 String clusterName)
      • getConfig

        protected Dom getConfig​(Dom domain,
                                String configName)
      • saveProperties

        protected jakarta.ws.rs.core.Response saveProperties​(Map<String,​String> data)
        Saves the passed map of system properties. Any entry with a null or empty value will be deleted with the delete-system-property command, and the rest will then be created with create-system-properties.
        Parameters:
        data - a map of properties to create or delete
        Returns:
        the result of the command
      • saveProperties

        protected jakarta.ws.rs.core.Response saveProperties​(String parent,
                                                             Map<String,​String> data)
        Saves the passed map of system properties. Any entry with a null or empty value will be deleted with the delete-system-property command, and the rest will then be created with create-system-properties.
        Parameters:
        parent - the name of the parent object of the target
        data - a map of properties to create or delete
        Returns:
        the result of the command
      • createProperties

        protected jakarta.ws.rs.core.Response createProperties​(String parent,
                                                               Map<String,​String> data)
        Create some system properties using the create-system-properties asadmin command.
        Parameters:
        parent - the name of the parent object of the target
        data - a map of properties to create
        Returns:
        the result of the command
      • deleteProperties

        protected jakarta.ws.rs.core.Response deleteProperties​(String parent,
                                                               Collection<String> propNames)
        Delete some system properties using the delete-system-property asadmin command and aggregating the results.
        Parameters:
        parent - the name of the parent object of the target
        propNames - the names of the properties to delete
        Returns:
        the result of the commands
      • deleteProperty

        protected jakarta.ws.rs.core.Response deleteProperty​(String parent,
                                                             String propName)
        Delete a system property using the delete-system-property asadmin command.
        Parameters:
        parent - the name of the parent object of the target
        propName - the name of the property to delete
        Returns:
        the result of the command
      • convertPropertyMapToString

        protected String convertPropertyMapToString​(Map<String,​String> data)