Class Build.SourceFile
java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
com.google.devtools.build.lib.query2.proto.proto2api.Build.SourceFile
- All Implemented Interfaces:
Build.SourceFileOrBuilder,com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Serializable
- Enclosing class:
- Build
public static final class Build.SourceFile
extends com.google.protobuf.GeneratedMessage
implements Build.SourceFileOrBuilder
A file that is an input into the build system. Next-Id: 10Protobuf type
blaze_query.SourceFile- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA file that is an input into the build system.Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessage
com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT, BuilderT>>, com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.FieldAccessorTable, com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message, T extends Object>, com.google.protobuf.GeneratedMessage.UnusedPrivateParameter Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessage
com.google.protobuf.AbstractMessage.BuilderParentNested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessage
alwaysUseFieldBuilders, unknownFieldsFields inherited from class com.google.protobuf.AbstractMessage
memoizedSizeFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic Build.SourceFilestatic final com.google.protobuf.Descriptors.DescriptorgetFeature(int index) The package-level features enabled for this package.com.google.protobuf.ByteStringgetFeatureBytes(int index) The package-level features enabled for this package.intThe package-level features enabled for this package.com.google.protobuf.ProtocolStringListThe package-level features enabled for this package.License attribute for the file.License attribute for the file.The location of the source file.com.google.protobuf.ByteStringThe location of the source file.getName()The name of the source file (a label).com.google.protobuf.ByteStringThe name of the source file (a label).booleanTrue if the package contains an error.getPackageGroup(int index) Labels of package groups that are mentioned in the visibility declaration for this source file.com.google.protobuf.ByteStringgetPackageGroupBytes(int index) Labels of package groups that are mentioned in the visibility declaration for this source file.intLabels of package groups that are mentioned in the visibility declaration for this source file.com.google.protobuf.ProtocolStringListLabels of package groups that are mentioned in the visibility declaration for this source file.com.google.protobuf.Parser<Build.SourceFile>intgetSubinclude(int index) Labels of .bzl (Starlark) files that are transitively loaded in this BUILD file.com.google.protobuf.ByteStringgetSubincludeBytes(int index) Labels of .bzl (Starlark) files that are transitively loaded in this BUILD file.intLabels of .bzl (Starlark) files that are transitively loaded in this BUILD file.com.google.protobuf.ProtocolStringListLabels of .bzl (Starlark) files that are transitively loaded in this BUILD file.getVisibilityLabel(int index) Labels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)com.google.protobuf.ByteStringgetVisibilityLabelBytes(int index) Labels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)intLabels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)com.google.protobuf.ProtocolStringListLabels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)inthashCode()booleanLicense attribute for the file.booleanThe location of the source file.booleanhasName()The name of the source file (a label).booleanTrue if the package contains an error.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanstatic Build.SourceFile.Builderstatic Build.SourceFile.BuildernewBuilder(Build.SourceFile prototype) protected Build.SourceFile.BuildernewBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent) static Build.SourceFileparseDelimitedFrom(InputStream input) static Build.SourceFileparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Build.SourceFileparseFrom(byte[] data) static Build.SourceFileparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Build.SourceFileparseFrom(com.google.protobuf.ByteString data) static Build.SourceFileparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Build.SourceFileparseFrom(com.google.protobuf.CodedInputStream input) static Build.SourceFileparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Build.SourceFileparseFrom(InputStream input) static Build.SourceFileparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Build.SourceFileparseFrom(ByteBuffer data) static Build.SourceFileparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<Build.SourceFile>parser()voidwriteTo(com.google.protobuf.CodedOutputStream output) Methods inherited from class com.google.protobuf.GeneratedMessage
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagMethods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashFields, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Field Details
-
NAME_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER- See Also:
-
LOCATION_FIELD_NUMBER
public static final int LOCATION_FIELD_NUMBER- See Also:
-
SUBINCLUDE_FIELD_NUMBER
public static final int SUBINCLUDE_FIELD_NUMBER- See Also:
-
PACKAGE_GROUP_FIELD_NUMBER
public static final int PACKAGE_GROUP_FIELD_NUMBER- See Also:
-
VISIBILITY_LABEL_FIELD_NUMBER
public static final int VISIBILITY_LABEL_FIELD_NUMBER- See Also:
-
FEATURE_FIELD_NUMBER
public static final int FEATURE_FIELD_NUMBER- See Also:
-
LICENSE_FIELD_NUMBER
public static final int LICENSE_FIELD_NUMBER- See Also:
-
PACKAGE_CONTAINS_ERRORS_FIELD_NUMBER
public static final int PACKAGE_CONTAINS_ERRORS_FIELD_NUMBER- See Also:
-
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage
-
hasName
public boolean hasName()The name of the source file (a label).
required string name = 1;- Specified by:
hasNamein interfaceBuild.SourceFileOrBuilder- Returns:
- Whether the name field is set.
-
getName
The name of the source file (a label).
required string name = 1;- Specified by:
getNamein interfaceBuild.SourceFileOrBuilder- Returns:
- The name.
-
getNameBytes
public com.google.protobuf.ByteString getNameBytes()The name of the source file (a label).
required string name = 1;- Specified by:
getNameBytesin interfaceBuild.SourceFileOrBuilder- Returns:
- The bytes for name.
-
hasLocation
public boolean hasLocation()The location of the source file. This is a path with a line number and a column number not a label in the build system.
optional string location = 2;- Specified by:
hasLocationin interfaceBuild.SourceFileOrBuilder- Returns:
- Whether the location field is set.
-
getLocation
The location of the source file. This is a path with a line number and a column number not a label in the build system.
optional string location = 2;- Specified by:
getLocationin interfaceBuild.SourceFileOrBuilder- Returns:
- The location.
-
getLocationBytes
public com.google.protobuf.ByteString getLocationBytes()The location of the source file. This is a path with a line number and a column number not a label in the build system.
optional string location = 2;- Specified by:
getLocationBytesin interfaceBuild.SourceFileOrBuilder- Returns:
- The bytes for location.
-
getSubincludeList
public com.google.protobuf.ProtocolStringList getSubincludeList()Labels of .bzl (Starlark) files that are transitively loaded in this BUILD file. This is present only when the SourceFile represents a BUILD file that loaded .bzl files. TODO(bazel-team): Rename this field.
repeated string subinclude = 3;- Specified by:
getSubincludeListin interfaceBuild.SourceFileOrBuilder- Returns:
- A list containing the subinclude.
-
getSubincludeCount
public int getSubincludeCount()Labels of .bzl (Starlark) files that are transitively loaded in this BUILD file. This is present only when the SourceFile represents a BUILD file that loaded .bzl files. TODO(bazel-team): Rename this field.
repeated string subinclude = 3;- Specified by:
getSubincludeCountin interfaceBuild.SourceFileOrBuilder- Returns:
- The count of subinclude.
-
getSubinclude
Labels of .bzl (Starlark) files that are transitively loaded in this BUILD file. This is present only when the SourceFile represents a BUILD file that loaded .bzl files. TODO(bazel-team): Rename this field.
repeated string subinclude = 3;- Specified by:
getSubincludein interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The subinclude at the given index.
-
getSubincludeBytes
public com.google.protobuf.ByteString getSubincludeBytes(int index) Labels of .bzl (Starlark) files that are transitively loaded in this BUILD file. This is present only when the SourceFile represents a BUILD file that loaded .bzl files. TODO(bazel-team): Rename this field.
repeated string subinclude = 3;- Specified by:
getSubincludeBytesin interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the subinclude at the given index.
-
getPackageGroupList
public com.google.protobuf.ProtocolStringList getPackageGroupList()Labels of package groups that are mentioned in the visibility declaration for this source file.
repeated string package_group = 4;- Specified by:
getPackageGroupListin interfaceBuild.SourceFileOrBuilder- Returns:
- A list containing the packageGroup.
-
getPackageGroupCount
public int getPackageGroupCount()Labels of package groups that are mentioned in the visibility declaration for this source file.
repeated string package_group = 4;- Specified by:
getPackageGroupCountin interfaceBuild.SourceFileOrBuilder- Returns:
- The count of packageGroup.
-
getPackageGroup
Labels of package groups that are mentioned in the visibility declaration for this source file.
repeated string package_group = 4;- Specified by:
getPackageGroupin interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The packageGroup at the given index.
-
getPackageGroupBytes
public com.google.protobuf.ByteString getPackageGroupBytes(int index) Labels of package groups that are mentioned in the visibility declaration for this source file.
repeated string package_group = 4;- Specified by:
getPackageGroupBytesin interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the packageGroup at the given index.
-
getVisibilityLabelList
public com.google.protobuf.ProtocolStringList getVisibilityLabelList()Labels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)
repeated string visibility_label = 5;- Specified by:
getVisibilityLabelListin interfaceBuild.SourceFileOrBuilder- Returns:
- A list containing the visibilityLabel.
-
getVisibilityLabelCount
public int getVisibilityLabelCount()Labels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)
repeated string visibility_label = 5;- Specified by:
getVisibilityLabelCountin interfaceBuild.SourceFileOrBuilder- Returns:
- The count of visibilityLabel.
-
getVisibilityLabel
Labels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)
repeated string visibility_label = 5;- Specified by:
getVisibilityLabelin interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The visibilityLabel at the given index.
-
getVisibilityLabelBytes
public com.google.protobuf.ByteString getVisibilityLabelBytes(int index) Labels mentioned in the visibility declaration (including :__pkg__ and //visibility: ones)
repeated string visibility_label = 5;- Specified by:
getVisibilityLabelBytesin interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the visibilityLabel at the given index.
-
getFeatureList
public com.google.protobuf.ProtocolStringList getFeatureList()The package-level features enabled for this package. Only present if the SourceFile represents a BUILD file.
repeated string feature = 6;- Specified by:
getFeatureListin interfaceBuild.SourceFileOrBuilder- Returns:
- A list containing the feature.
-
getFeatureCount
public int getFeatureCount()The package-level features enabled for this package. Only present if the SourceFile represents a BUILD file.
repeated string feature = 6;- Specified by:
getFeatureCountin interfaceBuild.SourceFileOrBuilder- Returns:
- The count of feature.
-
getFeature
The package-level features enabled for this package. Only present if the SourceFile represents a BUILD file.
repeated string feature = 6;- Specified by:
getFeaturein interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The feature at the given index.
-
getFeatureBytes
public com.google.protobuf.ByteString getFeatureBytes(int index) The package-level features enabled for this package. Only present if the SourceFile represents a BUILD file.
repeated string feature = 6;- Specified by:
getFeatureBytesin interfaceBuild.SourceFileOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the feature at the given index.
-
hasLicense
public boolean hasLicense()License attribute for the file.
optional .blaze_query.License license = 8;- Specified by:
hasLicensein interfaceBuild.SourceFileOrBuilder- Returns:
- Whether the license field is set.
-
getLicense
License attribute for the file.
optional .blaze_query.License license = 8;- Specified by:
getLicensein interfaceBuild.SourceFileOrBuilder- Returns:
- The license.
-
getLicenseOrBuilder
License attribute for the file.
optional .blaze_query.License license = 8;- Specified by:
getLicenseOrBuilderin interfaceBuild.SourceFileOrBuilder
-
hasPackageContainsErrors
public boolean hasPackageContainsErrors()True if the package contains an error. Only present if the SourceFile represents a BUILD file.
optional bool package_contains_errors = 9;- Specified by:
hasPackageContainsErrorsin interfaceBuild.SourceFileOrBuilder- Returns:
- Whether the packageContainsErrors field is set.
-
getPackageContainsErrors
public boolean getPackageContainsErrors()True if the package contains an error. Only present if the SourceFile represents a BUILD file.
optional bool package_contains_errors = 9;- Specified by:
getPackageContainsErrorsin interfaceBuild.SourceFileOrBuilder- Returns:
- The packageContainsErrors.
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage
-
writeTo
- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessage- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessage
-
equals
- Specified by:
equalsin interfacecom.google.protobuf.Message- Overrides:
equalsin classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()- Specified by:
hashCodein interfacecom.google.protobuf.Message- Overrides:
hashCodein classcom.google.protobuf.AbstractMessage
-
parseFrom
public static Build.SourceFile parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Build.SourceFile parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Build.SourceFile parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Build.SourceFile parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Build.SourceFile parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Build.SourceFile parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static Build.SourceFile parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static Build.SourceFile parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static Build.SourceFile parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static Build.SourceFile parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilderForType
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected Build.SourceFile.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent) - Overrides:
newBuilderForTypein classcom.google.protobuf.AbstractMessage
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessage
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-