public static enum Requirement.Type extends java.lang.Enum<Requirement.Type> implements com.google.protobuf.ProtocolMessageEnum
A classification of the requirement and how it is enforced.Protobuf enum
jscomp.Requirement.Type| Enum Constant and Description |
|---|
BANNED_CODE_PATTERN
A banned code pattern.
|
BANNED_DEPENDENCY
A forbidden source file
|
BANNED_NAME
A forbidden fully distinguished name.
|
BANNED_NAME_CALL
A banned function call.
|
BANNED_PROPERTY
A banned instance property, for example:
- An 'instance' property: "namespace.Foo.prototype.banned"
- All properties of a given name "Object.prototype.banned"
|
BANNED_PROPERTY_CALL
A banned function call.
|
BANNED_PROPERTY_NON_CONSTANT_WRITE
A banned write of a non-constant value to an instance property.
|
BANNED_PROPERTY_READ
A banned reading from an instance property, for example:
- An 'instance' property: "namespace.Foo.prototype.banned"
- All properties of a given name "Object.prototype.banned"
Unlike BANNED_PROPERTY, this only bans reads to the property,
i.e.
|
BANNED_PROPERTY_WRITE
A banned write to an instance property, for example:
- An 'instance' property: "namespace.Foo.prototype.banned"
- All properties of a given name "Object.prototype.banned"
Unlike BANNED_PROPERTY, this only bans assignments to the property,
i.e.
|
CUSTOM
A requirement enforced with code a external java class.
|
RESTRICTED_METHOD_CALL
A restricted call, for example:
- The unsafe opt_html parameter must not be passed to createNode:
goog.ui.tree.TreeControl.prototype.createNode:function()
|
RESTRICTED_NAME_CALL
A restricted call, for example:
- the "parseInt" call must be called with a radix:
parseInt:function(string, int)
|
| Modifier and Type | Field and Description |
|---|---|
static int |
BANNED_CODE_PATTERN_VALUE
A banned code pattern.
|
static int |
BANNED_DEPENDENCY_VALUE
A forbidden source file
|
static int |
BANNED_NAME_CALL_VALUE
A banned function call.
|
static int |
BANNED_NAME_VALUE
A forbidden fully distinguished name.
|
static int |
BANNED_PROPERTY_CALL_VALUE
A banned function call.
|
static int |
BANNED_PROPERTY_NON_CONSTANT_WRITE_VALUE
A banned write of a non-constant value to an instance property.
|
static int |
BANNED_PROPERTY_READ_VALUE
A banned reading from an instance property, for example:
- An 'instance' property: "namespace.Foo.prototype.banned"
- All properties of a given name "Object.prototype.banned"
Unlike BANNED_PROPERTY, this only bans reads to the property,
i.e.
|
static int |
BANNED_PROPERTY_VALUE
A banned instance property, for example:
- An 'instance' property: "namespace.Foo.prototype.banned"
- All properties of a given name "Object.prototype.banned"
|
static int |
BANNED_PROPERTY_WRITE_VALUE
A banned write to an instance property, for example:
- An 'instance' property: "namespace.Foo.prototype.banned"
- All properties of a given name "Object.prototype.banned"
Unlike BANNED_PROPERTY, this only bans assignments to the property,
i.e.
|
static int |
CUSTOM_VALUE
A requirement enforced with code a external java class.
|
static int |
RESTRICTED_METHOD_CALL_VALUE
A restricted call, for example:
- The unsafe opt_html parameter must not be passed to createNode:
goog.ui.tree.TreeControl.prototype.createNode:function()
|
static int |
RESTRICTED_NAME_CALL_VALUE
A restricted call, for example:
- the "parseInt" call must be called with a radix:
parseInt:function(string, int)
|
| Modifier and Type | Method and Description |
|---|---|
static Requirement.Type |
forNumber(int value) |
static com.google.protobuf.Descriptors.EnumDescriptor |
getDescriptor() |
com.google.protobuf.Descriptors.EnumDescriptor |
getDescriptorForType() |
int |
getNumber() |
com.google.protobuf.Descriptors.EnumValueDescriptor |
getValueDescriptor() |
static com.google.protobuf.Internal.EnumLiteMap<Requirement.Type> |
internalGetValueMap() |
static Requirement.Type |
valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) |
static Requirement.Type |
valueOf(int value)
Deprecated.
Use
forNumber(int) instead. |
static Requirement.Type |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static Requirement.Type[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Requirement.Type CUSTOM
A requirement enforced with code a external java class.
CUSTOM = 1;public static final Requirement.Type BANNED_DEPENDENCY
A forbidden source file
BANNED_DEPENDENCY = 2;public static final Requirement.Type BANNED_NAME
A forbidden fully distinguished name. For example: - A global name like "eval" or "goog" - A namespaced value or type: namespace.Banned - A 'static' property: "namespace.Foo.banned"
BANNED_NAME = 3;public static final Requirement.Type BANNED_PROPERTY
A banned instance property, for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned"
BANNED_PROPERTY = 4;public static final Requirement.Type BANNED_PROPERTY_READ
A banned reading from an instance property, for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned" Unlike BANNED_PROPERTY, this only bans reads to the property, i.e. its use as an rvalue.
BANNED_PROPERTY_READ = 5;public static final Requirement.Type BANNED_PROPERTY_WRITE
A banned write to an instance property, for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned" Unlike BANNED_PROPERTY, this only bans assignments to the property, i.e. its use as an lvalue.
BANNED_PROPERTY_WRITE = 6;public static final Requirement.Type RESTRICTED_NAME_CALL
A restricted call, for example: - the "parseInt" call must be called with a radix: parseInt:function(string, int)
RESTRICTED_NAME_CALL = 7;public static final Requirement.Type RESTRICTED_METHOD_CALL
A restricted call, for example: - The unsafe opt_html parameter must not be passed to createNode: goog.ui.tree.TreeControl.prototype.createNode:function()
RESTRICTED_METHOD_CALL = 8;public static final Requirement.Type BANNED_CODE_PATTERN
A banned code pattern. This check is done using against an AST.
To ban a call to eval:
"/** @param {?} a */ function template(a) {eval(a);}"
BANNED_CODE_PATTERN = 9;public static final Requirement.Type BANNED_PROPERTY_CALL
A banned function call. for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned" Unlike BANNED_PROPERTY, this only bans calls to the property i.e. using the property as a value is allowed.
BANNED_PROPERTY_CALL = 10;public static final Requirement.Type BANNED_PROPERTY_NON_CONSTANT_WRITE
A banned write of a non-constant value to an instance property. Unlike BANNED_PROPERTY_WRITE, this only bans assignments of a non-constant value.
BANNED_PROPERTY_NON_CONSTANT_WRITE = 11;public static final Requirement.Type BANNED_NAME_CALL
A banned function call. Unlike BANNED_NAME, this only bans calls to the property, i.e. using the property as a value is allowed.
BANNED_NAME_CALL = 12;public static final int CUSTOM_VALUE
A requirement enforced with code a external java class.
CUSTOM = 1;public static final int BANNED_DEPENDENCY_VALUE
A forbidden source file
BANNED_DEPENDENCY = 2;public static final int BANNED_NAME_VALUE
A forbidden fully distinguished name. For example: - A global name like "eval" or "goog" - A namespaced value or type: namespace.Banned - A 'static' property: "namespace.Foo.banned"
BANNED_NAME = 3;public static final int BANNED_PROPERTY_VALUE
A banned instance property, for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned"
BANNED_PROPERTY = 4;public static final int BANNED_PROPERTY_READ_VALUE
A banned reading from an instance property, for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned" Unlike BANNED_PROPERTY, this only bans reads to the property, i.e. its use as an rvalue.
BANNED_PROPERTY_READ = 5;public static final int BANNED_PROPERTY_WRITE_VALUE
A banned write to an instance property, for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned" Unlike BANNED_PROPERTY, this only bans assignments to the property, i.e. its use as an lvalue.
BANNED_PROPERTY_WRITE = 6;public static final int RESTRICTED_NAME_CALL_VALUE
A restricted call, for example: - the "parseInt" call must be called with a radix: parseInt:function(string, int)
RESTRICTED_NAME_CALL = 7;public static final int RESTRICTED_METHOD_CALL_VALUE
A restricted call, for example: - The unsafe opt_html parameter must not be passed to createNode: goog.ui.tree.TreeControl.prototype.createNode:function()
RESTRICTED_METHOD_CALL = 8;public static final int BANNED_CODE_PATTERN_VALUE
A banned code pattern. This check is done using against an AST.
To ban a call to eval:
"/** @param {?} a */ function template(a) {eval(a);}"
BANNED_CODE_PATTERN = 9;public static final int BANNED_PROPERTY_CALL_VALUE
A banned function call. for example: - An 'instance' property: "namespace.Foo.prototype.banned" - All properties of a given name "Object.prototype.banned" Unlike BANNED_PROPERTY, this only bans calls to the property i.e. using the property as a value is allowed.
BANNED_PROPERTY_CALL = 10;public static final int BANNED_PROPERTY_NON_CONSTANT_WRITE_VALUE
A banned write of a non-constant value to an instance property. Unlike BANNED_PROPERTY_WRITE, this only bans assignments of a non-constant value.
BANNED_PROPERTY_NON_CONSTANT_WRITE = 11;public static final int BANNED_NAME_CALL_VALUE
A banned function call. Unlike BANNED_NAME, this only bans calls to the property, i.e. using the property as a value is allowed.
BANNED_NAME_CALL = 12;public static Requirement.Type[] values()
for (Requirement.Type c : Requirement.Type.values()) System.out.println(c);
public static Requirement.Type valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant with the specified namejava.lang.NullPointerException - if the argument is nullpublic final int getNumber()
getNumber in interface com.google.protobuf.Internal.EnumLitegetNumber in interface com.google.protobuf.ProtocolMessageEnum@Deprecated public static Requirement.Type valueOf(int value)
forNumber(int) instead.public static Requirement.Type forNumber(int value)
public static com.google.protobuf.Internal.EnumLiteMap<Requirement.Type> internalGetValueMap()
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
getValueDescriptor in interface com.google.protobuf.ProtocolMessageEnumpublic final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.ProtocolMessageEnumpublic static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor()
public static Requirement.Type valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
Copyright © 2009-2018 Google. All Rights Reserved.