Enum GerritTriggerParameters

    • Enum Constant Detail

      • GERRIT_CHANGE_PRIVATE_STATE

        public static final GerritTriggerParameters GERRIT_CHANGE_PRIVATE_STATE
        Parameter name for change private state.
      • GERRIT_CHANGE_WIP_STATE

        public static final GerritTriggerParameters GERRIT_CHANGE_WIP_STATE
        Parameter name for change wip state.
      • GERRIT_CHANGE_SUBJECT

        public static final GerritTriggerParameters GERRIT_CHANGE_SUBJECT
        Parameter name for the commit subject (commit message's 1st line).
      • GERRIT_CHANGE_COMMIT_MESSAGE

        public static final GerritTriggerParameters GERRIT_CHANGE_COMMIT_MESSAGE
        Parameter name for the full commit message.
      • GERRIT_OLD_TOPIC

        public static final GerritTriggerParameters GERRIT_OLD_TOPIC
        Parameter name for the old topic (in case of topic was changed).
      • GERRIT_TOPIC_CHANGER

        public static final GerritTriggerParameters GERRIT_TOPIC_CHANGER
        The name and email of the changer of the topic.
      • GERRIT_TOPIC_CHANGER_NAME

        public static final GerritTriggerParameters GERRIT_TOPIC_CHANGER_NAME
        The name of the changer of the topic.
      • GERRIT_TOPIC_CHANGER_EMAIL

        public static final GerritTriggerParameters GERRIT_TOPIC_CHANGER_EMAIL
        The email of the changer of the topic.
      • GERRIT_TOPIC_CHANGER_USERNAME

        public static final GerritTriggerParameters GERRIT_TOPIC_CHANGER_USERNAME
        The username of the changer of the topic.
      • GERRIT_CHANGE_NUMBER

        public static final GerritTriggerParameters GERRIT_CHANGE_NUMBER
        Parameter name for the change number.
      • GERRIT_CHANGE_URL

        public static final GerritTriggerParameters GERRIT_CHANGE_URL
        Parameter name for the URL to the change.
      • GERRIT_PATCHSET_NUMBER

        public static final GerritTriggerParameters GERRIT_PATCHSET_NUMBER
        Parameter name for the patch set number.
      • GERRIT_PATCHSET_REVISION

        public static final GerritTriggerParameters GERRIT_PATCHSET_REVISION
        Parameter name for the patch set revision.
      • GERRIT_PROJECT

        public static final GerritTriggerParameters GERRIT_PROJECT
        Parameter name for the Gerrit project name.
      • GERRIT_CHANGE_ABANDONER

        public static final GerritTriggerParameters GERRIT_CHANGE_ABANDONER
        The name and email of the abandoner of the change.
      • GERRIT_CHANGE_ABANDONER_NAME

        public static final GerritTriggerParameters GERRIT_CHANGE_ABANDONER_NAME
        The name of the abandoner of the change.
      • GERRIT_CHANGE_ABANDONER_EMAIL

        public static final GerritTriggerParameters GERRIT_CHANGE_ABANDONER_EMAIL
        The email of the abandoner of the change.
      • GERRIT_CHANGE_ABANDONER_USERNAME

        public static final GerritTriggerParameters GERRIT_CHANGE_ABANDONER_USERNAME
        The username of the abandoner of the change.
      • GERRIT_CHANGE_OWNER

        public static final GerritTriggerParameters GERRIT_CHANGE_OWNER
        The name and email of the owner of the change.
      • GERRIT_CHANGE_OWNER_NAME

        public static final GerritTriggerParameters GERRIT_CHANGE_OWNER_NAME
        The name of the owner of the change.
      • GERRIT_CHANGE_OWNER_EMAIL

        public static final GerritTriggerParameters GERRIT_CHANGE_OWNER_EMAIL
        The email of the owner of the change.
      • GERRIT_CHANGE_OWNER_USERNAME

        public static final GerritTriggerParameters GERRIT_CHANGE_OWNER_USERNAME
        The username of the owner of the change.
      • GERRIT_CHANGE_RESTORER

        public static final GerritTriggerParameters GERRIT_CHANGE_RESTORER
        The name and email of the restorer of the change.
      • GERRIT_CHANGE_RESTORER_NAME

        public static final GerritTriggerParameters GERRIT_CHANGE_RESTORER_NAME
        The name of the restorer of the change.
      • GERRIT_CHANGE_RESTORER_EMAIL

        public static final GerritTriggerParameters GERRIT_CHANGE_RESTORER_EMAIL
        The email of the restorer of the change.
      • GERRIT_CHANGE_RESTORER_USERNAME

        public static final GerritTriggerParameters GERRIT_CHANGE_RESTORER_USERNAME
        The username of the restorer of the change.
      • GERRIT_PATCHSET_UPLOADER

        public static final GerritTriggerParameters GERRIT_PATCHSET_UPLOADER
        The name and email of the uploader of the patch-set.
      • GERRIT_PATCHSET_UPLOADER_NAME

        public static final GerritTriggerParameters GERRIT_PATCHSET_UPLOADER_NAME
        The name of the uploader of the patch-set.
      • GERRIT_PATCHSET_UPLOADER_EMAIL

        public static final GerritTriggerParameters GERRIT_PATCHSET_UPLOADER_EMAIL
        The email of the uploader of the patch-set.
      • GERRIT_PATCHSET_UPLOADER_USERNAME

        public static final GerritTriggerParameters GERRIT_PATCHSET_UPLOADER_USERNAME
        The username of the uploader of the patch-set.
      • GERRIT_EVENT_ACCOUNT

        public static final GerritTriggerParameters GERRIT_EVENT_ACCOUNT
        The name and email of the person who triggered the event.
      • GERRIT_EVENT_ACCOUNT_NAME

        public static final GerritTriggerParameters GERRIT_EVENT_ACCOUNT_NAME
        The name of the person who triggered the event.
      • GERRIT_EVENT_ACCOUNT_EMAIL

        public static final GerritTriggerParameters GERRIT_EVENT_ACCOUNT_EMAIL
        The email of the person who triggered the event.
      • GERRIT_EVENT_ACCOUNT_USERNAME

        public static final GerritTriggerParameters GERRIT_EVENT_ACCOUNT_USERNAME
        The username of the person who triggered the event.
      • GERRIT_OLDREV

        public static final GerritTriggerParameters GERRIT_OLDREV
        The old revision in a ref-updated event.
      • GERRIT_NEWREV

        public static final GerritTriggerParameters GERRIT_NEWREV
        The new revision in a ref-updated or change-merged event.
      • GERRIT_SUBMITTER

        public static final GerritTriggerParameters GERRIT_SUBMITTER
        The submitter in a ref-updated event.
      • GERRIT_SUBMITTER_NAME

        public static final GerritTriggerParameters GERRIT_SUBMITTER_NAME
        The name of the submitter in a ref-updated event.
      • GERRIT_SUBMITTER_EMAIL

        public static final GerritTriggerParameters GERRIT_SUBMITTER_EMAIL
        The email of the submitter in a ref-updated event.
      • GERRIT_SUBMITTER_USERNAME

        public static final GerritTriggerParameters GERRIT_SUBMITTER_USERNAME
        The username of the submitter in a ref-updated event.
      • GERRIT_SCHEME

        public static final GerritTriggerParameters GERRIT_SCHEME
        The protocol scheme of the Gerrit instance.
      • GERRIT_EVENT_HASH

        public static final GerritTriggerParameters GERRIT_EVENT_HASH
        A hashcode of the Gerrit event object, to make sure every set of parameters is unique (allowing jenkins to queue duplicate builds).
      • GERRIT_EVENT_COMMENT_TEXT

        public static final GerritTriggerParameters GERRIT_EVENT_COMMENT_TEXT
        Comment posted to Gerrit in a comment-added event.
      • GERRIT_EVENT_UPDATED_APPROVALS

        public static final GerritTriggerParameters GERRIT_EVENT_UPDATED_APPROVALS
        Updated approvals.
      • GERRIT_HASHTAGS

        public static final GerritTriggerParameters GERRIT_HASHTAGS
        Hashtags posted to Gerrit in a change based event.
      • GERRIT_REMOVED_HASHTAGS

        public static final GerritTriggerParameters GERRIT_REMOVED_HASHTAGS
        Hashtags removed to Gerrit in a hashtags-changed event.
      • GERRIT_ADDED_HASHTAGS

        public static final GerritTriggerParameters GERRIT_ADDED_HASHTAGS
        Hashtags added to Gerrit in a hashtags-changed event.
    • Method Detail

      • values

        public static GerritTriggerParameters[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (GerritTriggerParameters c : GerritTriggerParameters.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static GerritTriggerParameters valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • getNamesSet

        public static Set<String> getNamesSet()
        A set of all the declared parameter names.
        Returns:
        the names of the parameters
        See Also:
        values(), Enum.name()
      • setOrCreateStringParameterValue

        public void setOrCreateStringParameterValue​(List<ParameterValue> parameters,
                                                    String value,
                                                    boolean escapeQuotes)
        Creates a StringParameterValue and adds it to the provided list. If the parameter with the same name already exists in the list it will be replaced by the new parameter, but its description will be used, unless the parameter type is something else than a StringParameterValue.
        Parameters:
        parameters - the list of existing parameters.
        value - the value.
        escapeQuotes - if quote characters should be escaped.
      • setOrCreateTextParameterValue

        public void setOrCreateTextParameterValue​(List<ParameterValue> parameters,
                                                  String value,
                                                  boolean escapeQuotes)
        Creates a TextParameterValue and adds it to the provided list. If the parameter with the same name already exists in the list it will be replaced by the new parameter, but its description will be used, unless the parameter type is something else than a TextParameterValue.
        Parameters:
        parameters - the list of existing parameters.
        value - the value.
        escapeQuotes - if quote characters should be escaped.
      • setOrCreateBase64EncodedStringParameterValue

        public void setOrCreateBase64EncodedStringParameterValue​(List<ParameterValue> parameters,
                                                                 String value,
                                                                 boolean escapeQuotes)
        Creates a Base64EncodedStringParameterValue and adds it to the provided list. If the parameter with the same name already exists in the list it will be replaced by the new parameter, but its description will be used, unless the parameter type is something else than a Base64EncodedStringParameterValue.
        Parameters:
        parameters - the list of existing parameters.
        value - the value.
        escapeQuotes - if quote characters should be escaped.
      • setOrCreateParameters

        public static void setOrCreateParameters​(com.sonymobile.tools.gerrit.gerritevents.dto.events.GerritTriggeredEvent gerritEvent,
                                                 Job project,
                                                 List<ParameterValue> parameters)
        Adds or sets all the Gerrit-parameter values to the provided list.
        Parameters:
        gerritEvent - the event.
        project - the project for which the parameters are being set
        parameters - the default parameters
        See Also:
        setOrCreateStringParameterValue(java.util.List, String, boolean)