Class Requirement

  • All Implemented Interfaces:
    RequirementOrBuilder, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<Requirement>, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, java.io.Serializable

    public final class Requirement
    extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<Requirement>
    implements RequirementOrBuilder
     A specification of code requirements
     NEXT ID: 17
     
    Protobuf type jscomp.Requirement
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  Requirement.Builder
      A specification of code requirements NEXT ID: 17
      static class  Requirement.Severity
      With what severity to report the issue by default.
      static class  Requirement.Type
      A classification of the requirement and how it is enforced.
      static class  Requirement.TypeMatchingStrategy
      Protobuf enum jscomp.Requirement.TypeMatchingStrategy
      static class  Requirement.WhitelistEntry
      Protobuf type jscomp.Requirement.WhitelistEntry
      static interface  Requirement.WhitelistEntryOrBuilder  
      • Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3.ExtendableMessage

        com.google.protobuf.GeneratedMessageV3.ExtendableMessage.ExtensionWriter
      • Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3

        com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,​BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,​BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
      • Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite

        com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object obj)  
      boolean getAllowExtendingValue()
      Whether to allow subconfigs to extend the "value" field.
      java.lang.String getConfigFile​(int index)
      The file(s) that defined this requirement.
      com.google.protobuf.ByteString getConfigFileBytes​(int index)
      The file(s) that defined this requirement.
      int getConfigFileCount()
      The file(s) that defined this requirement.
      com.google.protobuf.ProtocolStringList getConfigFileList()
      The file(s) that defined this requirement.
      static Requirement getDefaultInstance()  
      Requirement getDefaultInstanceForType()  
      static com.google.protobuf.Descriptors.Descriptor getDescriptor()  
      java.lang.String getErrorMessage()
      Required: The message to report when a requirement is violated.
      com.google.protobuf.ByteString getErrorMessageBytes()
      Required: The message to report when a requirement is violated.
      java.lang.String getExtends()
      Allows extending whitelists of rules with the specified rule_id.
      com.google.protobuf.ByteString getExtendsBytes()
      Allows extending whitelists of rules with the specified rule_id.
      java.lang.String getJavaClass()
      For "custom" requirements, the Java class used to enforce the requirement.
      com.google.protobuf.ByteString getJavaClassBytes()
      For "custom" requirements, the Java class used to enforce the requirement.
      java.lang.String getOnlyApplyTo​(int index)
      Optional: A list of source paths that will be checked for the requirement (the opposite of whitelist).
      com.google.protobuf.ByteString getOnlyApplyToBytes​(int index)
      Optional: A list of source paths that will be checked for the requirement (the opposite of whitelist).
      int getOnlyApplyToCount()
      Optional: A list of source paths that will be checked for the requirement (the opposite of whitelist).
      com.google.protobuf.ProtocolStringList getOnlyApplyToList()
      Optional: A list of source paths that will be checked for the requirement (the opposite of whitelist).
      java.lang.String getOnlyApplyToRegexp​(int index)
      Optional: A list of source path regexps that will be checked for the requirement (the opposite of whitelist_regexp).
      com.google.protobuf.ByteString getOnlyApplyToRegexpBytes​(int index)
      Optional: A list of source path regexps that will be checked for the requirement (the opposite of whitelist_regexp).
      int getOnlyApplyToRegexpCount()
      Optional: A list of source path regexps that will be checked for the requirement (the opposite of whitelist_regexp).
      com.google.protobuf.ProtocolStringList getOnlyApplyToRegexpList()
      Optional: A list of source path regexps that will be checked for the requirement (the opposite of whitelist_regexp).
      com.google.protobuf.Parser<Requirement> getParserForType()  
      boolean getReportLooseTypeViolations()
      Whether to report possible violations when type information is not exact.
      java.lang.String getRuleId()
      Gives the rule an unique ID that can be used for extending in other rules through 'extends'.
      com.google.protobuf.ByteString getRuleIdBytes()
      Gives the rule an unique ID that can be used for extending in other rules through 'extends'.
      int getSerializedSize()  
      Requirement.Severity getSeverity()
      optional .jscomp.Requirement.Severity severity = 12 [default = WARNING];
      Requirement.Type getType()
      Required: The type of requirement.
      Requirement.TypeMatchingStrategy getTypeMatchingStrategy()
      Strategy to use for matching types in the value parameter (e.g.
      com.google.protobuf.UnknownFieldSet getUnknownFields()  
      java.lang.String getValue​(int index)
      The value banned, optional for "custom" requirements.
      com.google.protobuf.ByteString getValueBytes​(int index)
      The value banned, optional for "custom" requirements.
      int getValueCount()
      The value banned, optional for "custom" requirements.
      com.google.protobuf.ProtocolStringList getValueList()
      The value banned, optional for "custom" requirements.
      java.lang.String getWhitelist​(int index)
      Optional: A list of source path prefixes that are exempt from the requirement.
      com.google.protobuf.ByteString getWhitelistBytes​(int index)
      Optional: A list of source path prefixes that are exempt from the requirement.
      int getWhitelistCount()
      Optional: A list of source path prefixes that are exempt from the requirement.
      Requirement.WhitelistEntry getWhitelistEntry​(int index)
      repeated .jscomp.Requirement.WhitelistEntry whitelist_entry = 14;
      int getWhitelistEntryCount()
      repeated .jscomp.Requirement.WhitelistEntry whitelist_entry = 14;
      java.util.List<Requirement.WhitelistEntry> getWhitelistEntryList()
      repeated .jscomp.Requirement.WhitelistEntry whitelist_entry = 14;
      Requirement.WhitelistEntryOrBuilder getWhitelistEntryOrBuilder​(int index)
      repeated .jscomp.Requirement.WhitelistEntry whitelist_entry = 14;
      java.util.List<? extends Requirement.WhitelistEntryOrBuilder> getWhitelistEntryOrBuilderList()
      repeated .jscomp.Requirement.WhitelistEntry whitelist_entry = 14;
      com.google.protobuf.ProtocolStringList getWhitelistList()
      Optional: A list of source path prefixes that are exempt from the requirement.
      java.lang.String getWhitelistRegexp​(int index)
      Optional: A list of source paths regexs that are exempt from the requirement.
      com.google.protobuf.ByteString getWhitelistRegexpBytes​(int index)
      Optional: A list of source paths regexs that are exempt from the requirement.
      int getWhitelistRegexpCount()
      Optional: A list of source paths regexs that are exempt from the requirement.
      com.google.protobuf.ProtocolStringList getWhitelistRegexpList()
      Optional: A list of source paths regexs that are exempt from the requirement.
      boolean hasAllowExtendingValue()
      Whether to allow subconfigs to extend the "value" field.
      boolean hasErrorMessage()
      Required: The message to report when a requirement is violated.
      boolean hasExtends()
      Allows extending whitelists of rules with the specified rule_id.
      int hashCode()  
      boolean hasJavaClass()
      For "custom" requirements, the Java class used to enforce the requirement.
      boolean hasReportLooseTypeViolations()
      Whether to report possible violations when type information is not exact.
      boolean hasRuleId()
      Gives the rule an unique ID that can be used for extending in other rules through 'extends'.
      boolean hasSeverity()
      optional .jscomp.Requirement.Severity severity = 12 [default = WARNING];
      boolean hasType()
      Required: The type of requirement.
      boolean hasTypeMatchingStrategy()
      Strategy to use for matching types in the value parameter (e.g.
      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()  
      boolean isInitialized()  
      static Requirement.Builder newBuilder()  
      static Requirement.Builder newBuilder​(Requirement prototype)  
      Requirement.Builder newBuilderForType()  
      protected Requirement.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)  
      protected java.lang.Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)  
      static Requirement parseDelimitedFrom​(java.io.InputStream input)  
      static Requirement parseDelimitedFrom​(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Requirement parseFrom​(byte[] data)  
      static Requirement parseFrom​(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Requirement parseFrom​(com.google.protobuf.ByteString data)  
      static Requirement parseFrom​(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Requirement parseFrom​(com.google.protobuf.CodedInputStream input)  
      static Requirement parseFrom​(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Requirement parseFrom​(java.io.InputStream input)  
      static Requirement parseFrom​(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static Requirement parseFrom​(java.nio.ByteBuffer data)  
      static Requirement parseFrom​(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)  
      static com.google.protobuf.Parser<Requirement> parser()  
      Requirement.Builder toBuilder()  
      void writeTo​(com.google.protobuf.CodedOutputStream output)  
      • Methods inherited from class com.google.protobuf.GeneratedMessageV3.ExtendableMessage

        extensionsAreInitialized, extensionsSerializedSize, extensionsSerializedSizeAsMessageSet, getAllFields, getAllFieldsRaw, getExtension, getExtension, getExtension, getExtension, getExtension, getExtension, getExtensionCount, getExtensionCount, getExtensionCount, getExtensionFields, getField, getRepeatedField, getRepeatedFieldCount, hasExtension, hasExtension, hasExtension, hasField, makeExtensionsImmutable, newExtensionWriter, newMessageSetExtensionWriter, parseUnknownField, parseUnknownFieldProto3
      • Methods inherited from class com.google.protobuf.GeneratedMessageV3

        canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getDescriptorForType, getOneofFieldDescriptor, hasOneof, internalGetMapField, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
      • Methods inherited from class com.google.protobuf.AbstractMessage

        findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
      • Methods inherited from class com.google.protobuf.AbstractMessageLite

        addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder

        getExtension, getExtension, getExtension, getExtension, getExtension, getExtension, getExtensionCount, getExtensionCount, getExtensionCount, hasExtension, hasExtension, hasExtension
      • Methods inherited from interface com.google.protobuf.MessageLite

        toByteArray, toByteString, writeDelimitedTo, writeTo
      • Methods inherited from interface com.google.protobuf.MessageOrBuilder

        findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof
    • Field Detail

      • ERROR_MESSAGE_FIELD_NUMBER

        public static final int ERROR_MESSAGE_FIELD_NUMBER
        See Also:
        Constant Field Values
      • WHITELIST_REGEXP_FIELD_NUMBER

        public static final int WHITELIST_REGEXP_FIELD_NUMBER
        See Also:
        Constant Field Values
      • WHITELIST_ENTRY_FIELD_NUMBER

        public static final int WHITELIST_ENTRY_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ONLY_APPLY_TO_FIELD_NUMBER

        public static final int ONLY_APPLY_TO_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ONLY_APPLY_TO_REGEXP_FIELD_NUMBER

        public static final int ONLY_APPLY_TO_REGEXP_FIELD_NUMBER
        See Also:
        Constant Field Values
      • ALLOW_EXTENDING_VALUE_FIELD_NUMBER

        public static final int ALLOW_EXTENDING_VALUE_FIELD_NUMBER
        See Also:
        Constant Field Values
      • TYPE_MATCHING_STRATEGY_FIELD_NUMBER

        public static final int TYPE_MATCHING_STRATEGY_FIELD_NUMBER
        See Also:
        Constant Field Values
      • JAVA_CLASS_FIELD_NUMBER

        public static final int JAVA_CLASS_FIELD_NUMBER
        See Also:
        Constant Field Values
      • REPORT_LOOSE_TYPE_VIOLATIONS_FIELD_NUMBER

        public static final int REPORT_LOOSE_TYPE_VIOLATIONS_FIELD_NUMBER
        See Also:
        Constant Field Values
      • CONFIG_FILE_FIELD_NUMBER

        public static final int CONFIG_FILE_FIELD_NUMBER
        See Also:
        Constant Field Values
      • PARSER

        @Deprecated
        public static final com.google.protobuf.Parser<Requirement> PARSER
        Deprecated.
    • Method Detail

      • newInstance

        protected java.lang.Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getUnknownFields

        public final com.google.protobuf.UnknownFieldSet getUnknownFields()
        Specified by:
        getUnknownFields in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getUnknownFields in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • hasErrorMessage

        public boolean hasErrorMessage()
         Required: The message to report when a requirement is violated. This should
         reference a document describing the reasoning for the requirement
         and contacts.
         
        optional string error_message = 1;
        Specified by:
        hasErrorMessage in interface RequirementOrBuilder
        Returns:
        Whether the errorMessage field is set.
      • getErrorMessage

        public java.lang.String getErrorMessage()
         Required: The message to report when a requirement is violated. This should
         reference a document describing the reasoning for the requirement
         and contacts.
         
        optional string error_message = 1;
        Specified by:
        getErrorMessage in interface RequirementOrBuilder
        Returns:
        The errorMessage.
      • getErrorMessageBytes

        public com.google.protobuf.ByteString getErrorMessageBytes()
         Required: The message to report when a requirement is violated. This should
         reference a document describing the reasoning for the requirement
         and contacts.
         
        optional string error_message = 1;
        Specified by:
        getErrorMessageBytes in interface RequirementOrBuilder
        Returns:
        The bytes for errorMessage.
      • getWhitelistList

        public com.google.protobuf.ProtocolStringList getWhitelistList()
         Optional: A list of source path prefixes that are exempt from the
         requirement.
         
        repeated string whitelist = 2;
        Specified by:
        getWhitelistList in interface RequirementOrBuilder
        Returns:
        A list containing the whitelist.
      • getWhitelistCount

        public int getWhitelistCount()
         Optional: A list of source path prefixes that are exempt from the
         requirement.
         
        repeated string whitelist = 2;
        Specified by:
        getWhitelistCount in interface RequirementOrBuilder
        Returns:
        The count of whitelist.
      • getWhitelist

        public java.lang.String getWhitelist​(int index)
         Optional: A list of source path prefixes that are exempt from the
         requirement.
         
        repeated string whitelist = 2;
        Specified by:
        getWhitelist in interface RequirementOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The whitelist at the given index.
      • getWhitelistBytes

        public com.google.protobuf.ByteString getWhitelistBytes​(int index)
         Optional: A list of source path prefixes that are exempt from the
         requirement.
         
        repeated string whitelist = 2;
        Specified by:
        getWhitelistBytes in interface RequirementOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the whitelist at the given index.
      • getWhitelistRegexpList

        public com.google.protobuf.ProtocolStringList getWhitelistRegexpList()
         Optional: A list of source paths regexs that are exempt from the
         requirement.
         
        repeated string whitelist_regexp = 3;
        Specified by:
        getWhitelistRegexpList in interface RequirementOrBuilder
        Returns:
        A list containing the whitelistRegexp.
      • getWhitelistRegexpCount

        public int getWhitelistRegexpCount()
         Optional: A list of source paths regexs that are exempt from the
         requirement.
         
        repeated string whitelist_regexp = 3;
        Specified by:
        getWhitelistRegexpCount in interface RequirementOrBuilder
        Returns:
        The count of whitelistRegexp.
      • getWhitelistRegexp

        public java.lang.String getWhitelistRegexp​(int index)
         Optional: A list of source paths regexs that are exempt from the
         requirement.
         
        repeated string whitelist_regexp = 3;
        Specified by:
        getWhitelistRegexp in interface RequirementOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The whitelistRegexp at the given index.
      • getWhitelistRegexpBytes

        public com.google.protobuf.ByteString getWhitelistRegexpBytes​(int index)
         Optional: A list of source paths regexs that are exempt from the
         requirement.
         
        repeated string whitelist_regexp = 3;
        Specified by:
        getWhitelistRegexpBytes in interface RequirementOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the whitelistRegexp at the given index.
      • getOnlyApplyToList

        public com.google.protobuf.ProtocolStringList getOnlyApplyToList()
         Optional: A list of source paths that will be checked for the requirement
         (the opposite of whitelist).
         
        repeated string only_apply_to = 4;
        Specified by:
        getOnlyApplyToList in interface RequirementOrBuilder
        Returns:
        A list containing the onlyApplyTo.
      • getOnlyApplyToCount

        public int getOnlyApplyToCount()
         Optional: A list of source paths that will be checked for the requirement
         (the opposite of whitelist).
         
        repeated string only_apply_to = 4;
        Specified by:
        getOnlyApplyToCount in interface RequirementOrBuilder
        Returns:
        The count of onlyApplyTo.
      • getOnlyApplyTo

        public java.lang.String getOnlyApplyTo​(int index)
         Optional: A list of source paths that will be checked for the requirement
         (the opposite of whitelist).
         
        repeated string only_apply_to = 4;
        Specified by:
        getOnlyApplyTo in interface RequirementOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The onlyApplyTo at the given index.
      • getOnlyApplyToBytes

        public com.google.protobuf.ByteString getOnlyApplyToBytes​(int index)
         Optional: A list of source paths that will be checked for the requirement
         (the opposite of whitelist).
         
        repeated string only_apply_to = 4;
        Specified by:
        getOnlyApplyToBytes in interface RequirementOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the onlyApplyTo at the given index.
      • getOnlyApplyToRegexpList

        public com.google.protobuf.ProtocolStringList getOnlyApplyToRegexpList()
         Optional: A list of source path regexps that will be checked for
         the requirement (the opposite of whitelist_regexp).
         
        repeated string only_apply_to_regexp = 5;
        Specified by:
        getOnlyApplyToRegexpList in interface RequirementOrBuilder
        Returns:
        A list containing the onlyApplyToRegexp.
      • getOnlyApplyToRegexpCount

        public int getOnlyApplyToRegexpCount()
         Optional: A list of source path regexps that will be checked for
         the requirement (the opposite of whitelist_regexp).
         
        repeated string only_apply_to_regexp = 5;
        Specified by:
        getOnlyApplyToRegexpCount in interface RequirementOrBuilder
        Returns:
        The count of onlyApplyToRegexp.
      • getOnlyApplyToRegexp

        public java.lang.String getOnlyApplyToRegexp​(int index)
         Optional: A list of source path regexps that will be checked for
         the requirement (the opposite of whitelist_regexp).
         
        repeated string only_apply_to_regexp = 5;
        Specified by:
        getOnlyApplyToRegexp in interface RequirementOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The onlyApplyToRegexp at the given index.
      • getOnlyApplyToRegexpBytes

        public com.google.protobuf.ByteString getOnlyApplyToRegexpBytes​(int index)
         Optional: A list of source path regexps that will be checked for
         the requirement (the opposite of whitelist_regexp).
         
        repeated string only_apply_to_regexp = 5;
        Specified by:
        getOnlyApplyToRegexpBytes in interface RequirementOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the onlyApplyToRegexp at the given index.
      • hasType

        public boolean hasType()
         Required: The type of requirement.
         
        optional .jscomp.Requirement.Type type = 6;
        Specified by:
        hasType in interface RequirementOrBuilder
        Returns:
        Whether the type field is set.
      • getValueList

        public com.google.protobuf.ProtocolStringList getValueList()
         The value banned, optional for "custom" requirements.  Some custom
         requirements repurpose this for different purposes, such as for whitelists
         of types.
         
        repeated string value = 7;
        Specified by:
        getValueList in interface RequirementOrBuilder
        Returns:
        A list containing the value.
      • getValueCount

        public int getValueCount()
         The value banned, optional for "custom" requirements.  Some custom
         requirements repurpose this for different purposes, such as for whitelists
         of types.
         
        repeated string value = 7;
        Specified by:
        getValueCount in interface RequirementOrBuilder
        Returns:
        The count of value.
      • getValue

        public java.lang.String getValue​(int index)
         The value banned, optional for "custom" requirements.  Some custom
         requirements repurpose this for different purposes, such as for whitelists
         of types.
         
        repeated string value = 7;
        Specified by:
        getValue in interface RequirementOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The value at the given index.
      • getValueBytes

        public com.google.protobuf.ByteString getValueBytes​(int index)
         The value banned, optional for "custom" requirements.  Some custom
         requirements repurpose this for different purposes, such as for whitelists
         of types.
         
        repeated string value = 7;
        Specified by:
        getValueBytes in interface RequirementOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the value at the given index.
      • hasAllowExtendingValue

        public boolean hasAllowExtendingValue()
         Whether to allow subconfigs to extend the "value" field.  This does not
         make sense for banning values, but when the value is used as a whitelist,
         it becomes important.
         
        optional bool allow_extending_value = 15;
        Specified by:
        hasAllowExtendingValue in interface RequirementOrBuilder
        Returns:
        Whether the allowExtendingValue field is set.
      • getAllowExtendingValue

        public boolean getAllowExtendingValue()
         Whether to allow subconfigs to extend the "value" field.  This does not
         make sense for banning values, but when the value is used as a whitelist,
         it becomes important.
         
        optional bool allow_extending_value = 15;
        Specified by:
        getAllowExtendingValue in interface RequirementOrBuilder
        Returns:
        The allowExtendingValue.
      • hasTypeMatchingStrategy

        public boolean hasTypeMatchingStrategy()
         Strategy to use for matching types in the value parameter (e.g. for
         BANNED_CODE_PATTERN checks).
         
        optional .jscomp.Requirement.TypeMatchingStrategy type_matching_strategy = 13 [default = LOOSE];
        Specified by:
        hasTypeMatchingStrategy in interface RequirementOrBuilder
        Returns:
        Whether the typeMatchingStrategy field is set.
      • getTypeMatchingStrategy

        public Requirement.TypeMatchingStrategy getTypeMatchingStrategy()
         Strategy to use for matching types in the value parameter (e.g. for
         BANNED_CODE_PATTERN checks).
         
        optional .jscomp.Requirement.TypeMatchingStrategy type_matching_strategy = 13 [default = LOOSE];
        Specified by:
        getTypeMatchingStrategy in interface RequirementOrBuilder
        Returns:
        The typeMatchingStrategy.
      • hasJavaClass

        public boolean hasJavaClass()
         For "custom" requirements, the Java class used to enforce the requirement.
         Ignored otherwise.
         
        optional string java_class = 8;
        Specified by:
        hasJavaClass in interface RequirementOrBuilder
        Returns:
        Whether the javaClass field is set.
      • getJavaClass

        public java.lang.String getJavaClass()
         For "custom" requirements, the Java class used to enforce the requirement.
         Ignored otherwise.
         
        optional string java_class = 8;
        Specified by:
        getJavaClass in interface RequirementOrBuilder
        Returns:
        The javaClass.
      • getJavaClassBytes

        public com.google.protobuf.ByteString getJavaClassBytes()
         For "custom" requirements, the Java class used to enforce the requirement.
         Ignored otherwise.
         
        optional string java_class = 8;
        Specified by:
        getJavaClassBytes in interface RequirementOrBuilder
        Returns:
        The bytes for javaClass.
      • hasRuleId

        public boolean hasRuleId()
         Gives the rule an unique ID that can be used for extending in other rules
         through 'extends'. An example of ID is 'closure:innerHtml'.
         
        optional string rule_id = 9;
        Specified by:
        hasRuleId in interface RequirementOrBuilder
        Returns:
        Whether the ruleId field is set.
      • getRuleId

        public java.lang.String getRuleId()
         Gives the rule an unique ID that can be used for extending in other rules
         through 'extends'. An example of ID is 'closure:innerHtml'.
         
        optional string rule_id = 9;
        Specified by:
        getRuleId in interface RequirementOrBuilder
        Returns:
        The ruleId.
      • getRuleIdBytes

        public com.google.protobuf.ByteString getRuleIdBytes()
         Gives the rule an unique ID that can be used for extending in other rules
         through 'extends'. An example of ID is 'closure:innerHtml'.
         
        optional string rule_id = 9;
        Specified by:
        getRuleIdBytes in interface RequirementOrBuilder
        Returns:
        The bytes for ruleId.
      • hasExtends

        public boolean hasExtends()
         Allows extending whitelists of rules with the specified rule_id. If this
         field is specified then all fields except whitelist, whitelist_regexp,
         only_apply_to and only_apply_to_regexp are ignored.
         
        optional string extends = 10;
        Specified by:
        hasExtends in interface RequirementOrBuilder
        Returns:
        Whether the extends field is set.
      • getExtends

        public java.lang.String getExtends()
         Allows extending whitelists of rules with the specified rule_id. If this
         field is specified then all fields except whitelist, whitelist_regexp,
         only_apply_to and only_apply_to_regexp are ignored.
         
        optional string extends = 10;
        Specified by:
        getExtends in interface RequirementOrBuilder
        Returns:
        The extends.
      • getExtendsBytes

        public com.google.protobuf.ByteString getExtendsBytes()
         Allows extending whitelists of rules with the specified rule_id. If this
         field is specified then all fields except whitelist, whitelist_regexp,
         only_apply_to and only_apply_to_regexp are ignored.
         
        optional string extends = 10;
        Specified by:
        getExtendsBytes in interface RequirementOrBuilder
        Returns:
        The bytes for extends.
      • hasReportLooseTypeViolations

        public boolean hasReportLooseTypeViolations()
         Whether to report possible violations when type information is not exact.
         Normally, violations on parent types are reported as possible violations.
         This field allows to ignore them and report only violations on exact types.
         This changes the balance between the false positives and the false
         negatives. With the default value, there might be lots of false positives
         (possible violations) but there shouldn't be any false negatives. Without
         reporting the loose type violations, there will be less false positives but
         there can also be false negatives (an actual violation that is not
         reported).
         
        optional bool report_loose_type_violations = 11 [default = true];
        Specified by:
        hasReportLooseTypeViolations in interface RequirementOrBuilder
        Returns:
        Whether the reportLooseTypeViolations field is set.
      • getReportLooseTypeViolations

        public boolean getReportLooseTypeViolations()
         Whether to report possible violations when type information is not exact.
         Normally, violations on parent types are reported as possible violations.
         This field allows to ignore them and report only violations on exact types.
         This changes the balance between the false positives and the false
         negatives. With the default value, there might be lots of false positives
         (possible violations) but there shouldn't be any false negatives. Without
         reporting the loose type violations, there will be less false positives but
         there can also be false negatives (an actual violation that is not
         reported).
         
        optional bool report_loose_type_violations = 11 [default = true];
        Specified by:
        getReportLooseTypeViolations in interface RequirementOrBuilder
        Returns:
        The reportLooseTypeViolations.
      • hasSeverity

        public boolean hasSeverity()
        optional .jscomp.Requirement.Severity severity = 12 [default = WARNING];
        Specified by:
        hasSeverity in interface RequirementOrBuilder
        Returns:
        Whether the severity field is set.
      • getConfigFileList

        public com.google.protobuf.ProtocolStringList getConfigFileList()
         The file(s) that defined this requirement.  If the requirement is extended,
         then all extending files are included as well.  These will be printed in
         the error message.
         
        repeated string config_file = 16;
        Specified by:
        getConfigFileList in interface RequirementOrBuilder
        Returns:
        A list containing the configFile.
      • getConfigFileCount

        public int getConfigFileCount()
         The file(s) that defined this requirement.  If the requirement is extended,
         then all extending files are included as well.  These will be printed in
         the error message.
         
        repeated string config_file = 16;
        Specified by:
        getConfigFileCount in interface RequirementOrBuilder
        Returns:
        The count of configFile.
      • getConfigFile

        public java.lang.String getConfigFile​(int index)
         The file(s) that defined this requirement.  If the requirement is extended,
         then all extending files are included as well.  These will be printed in
         the error message.
         
        repeated string config_file = 16;
        Specified by:
        getConfigFile in interface RequirementOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The configFile at the given index.
      • getConfigFileBytes

        public com.google.protobuf.ByteString getConfigFileBytes​(int index)
         The file(s) that defined this requirement.  If the requirement is extended,
         then all extending files are included as well.  These will be printed in
         the error message.
         
        repeated string config_file = 16;
        Specified by:
        getConfigFileBytes in interface RequirementOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the configFile at the given index.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.ExtendableMessage<Requirement>
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws java.io.IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        java.io.IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(java.lang.Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static Requirement parseFrom​(java.nio.ByteBuffer data)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Requirement parseFrom​(java.nio.ByteBuffer data,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Requirement parseFrom​(com.google.protobuf.ByteString data)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Requirement parseFrom​(com.google.protobuf.ByteString data,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Requirement parseFrom​(byte[] data)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Requirement parseFrom​(byte[] data,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Requirement parseFrom​(java.io.InputStream input)
                                     throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static Requirement parseFrom​(java.io.InputStream input,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws java.io.IOException
        Throws:
        java.io.IOException
      • parseDelimitedFrom

        public static Requirement parseDelimitedFrom​(java.io.InputStream input)
                                              throws java.io.IOException
        Throws:
        java.io.IOException
      • parseDelimitedFrom

        public static Requirement parseDelimitedFrom​(java.io.InputStream input,
                                                     com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                              throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static Requirement parseFrom​(com.google.protobuf.CodedInputStream input)
                                     throws java.io.IOException
        Throws:
        java.io.IOException
      • parseFrom

        public static Requirement parseFrom​(com.google.protobuf.CodedInputStream input,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws java.io.IOException
        Throws:
        java.io.IOException
      • newBuilderForType

        public Requirement.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public Requirement.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected Requirement.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstance

        public static Requirement getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<Requirement> parser()
      • getParserForType

        public com.google.protobuf.Parser<Requirement> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public Requirement getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<Requirement>
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder