diff options
author | Evgeny Mandrikov <mandrikov@gmail.com> | 2015-10-15 05:25:27 +0200 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@sonarsource.com> | 2015-10-29 16:12:28 +0100 |
commit | d7d20c58c771f3be6cc44b37dc5b741443beca03 (patch) | |
tree | 076800627d16da483866b467b52eba151d8f8f4b /sonar-batch-protocol/src | |
parent | bed7d7f1897ab5f0e2bfa0e4e6ac61e3d413c5dc (diff) | |
download | sonarqube-d7d20c58c771f3be6cc44b37dc5b741443beca03.tar.gz sonarqube-d7d20c58c771f3be6cc44b37dc5b741443beca03.zip |
Execute Protocol Buffer compiler during build
Dependency for compiler selected based on platform. Supported platforms
are Windows/Linux x86/64 and Mac OS. Configuration in root POM to avoid
duplication.
This also makes version of compiler consistent with version of library.
Previously it was 3.0.0-a3 and 3.0.0-beta-1 respectively, now both are
3.0.0-beta-1. And removes all existing auto generated files and scripts
for their creation as well as their traces (such as comments and
exclusions for SonarQube).
Diffstat (limited to 'sonar-batch-protocol/src')
5 files changed, 0 insertions, 22732 deletions
diff --git a/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/Constants.java b/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/Constants.java deleted file mode 100644 index 7eb449e1eaa..00000000000 --- a/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/Constants.java +++ /dev/null @@ -1,824 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: constants.proto - -package org.sonar.batch.protocol; - -public final class Constants { - private Constants() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - } - /** - * Protobuf enum {@code Severity} - */ - public enum Severity - implements com.google.protobuf.ProtocolMessageEnum { - /** - * <code>INFO = 0;</code> - */ - INFO(0, 0), - /** - * <code>MINOR = 1;</code> - */ - MINOR(1, 1), - /** - * <code>MAJOR = 2;</code> - */ - MAJOR(2, 2), - /** - * <code>CRITICAL = 3;</code> - */ - CRITICAL(3, 3), - /** - * <code>BLOCKER = 4;</code> - */ - BLOCKER(4, 4), - ; - - /** - * <code>INFO = 0;</code> - */ - public static final int INFO_VALUE = 0; - /** - * <code>MINOR = 1;</code> - */ - public static final int MINOR_VALUE = 1; - /** - * <code>MAJOR = 2;</code> - */ - public static final int MAJOR_VALUE = 2; - /** - * <code>CRITICAL = 3;</code> - */ - public static final int CRITICAL_VALUE = 3; - /** - * <code>BLOCKER = 4;</code> - */ - public static final int BLOCKER_VALUE = 4; - - - public final int getNumber() { - return value; - } - - public static Severity valueOf(int value) { - switch (value) { - case 0: return INFO; - case 1: return MINOR; - case 2: return MAJOR; - case 3: return CRITICAL; - case 4: return BLOCKER; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap<Severity> - internalGetValueMap() { - return internalValueMap; - } - private static com.google.protobuf.Internal.EnumLiteMap<Severity> - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap<Severity>() { - public Severity findValueByNumber(int number) { - return Severity.valueOf(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - return getDescriptor().getValues().get(index); - } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { - return getDescriptor(); - } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return org.sonar.batch.protocol.Constants.getDescriptor().getEnumTypes().get(0); - } - - private static final Severity[] VALUES = values(); - - public static Severity valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - return VALUES[desc.getIndex()]; - } - - private final int index; - private final int value; - - private Severity(int index, int value) { - this.index = index; - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:Severity) - } - - /** - * Protobuf enum {@code ComponentType} - */ - public enum ComponentType - implements com.google.protobuf.ProtocolMessageEnum { - /** - * <code>PROJECT = 0;</code> - */ - PROJECT(0, 0), - /** - * <code>MODULE = 1;</code> - */ - MODULE(1, 1), - /** - * <code>DIRECTORY = 2;</code> - */ - DIRECTORY(2, 2), - /** - * <code>FILE = 3;</code> - */ - FILE(3, 3), - ; - - /** - * <code>PROJECT = 0;</code> - */ - public static final int PROJECT_VALUE = 0; - /** - * <code>MODULE = 1;</code> - */ - public static final int MODULE_VALUE = 1; - /** - * <code>DIRECTORY = 2;</code> - */ - public static final int DIRECTORY_VALUE = 2; - /** - * <code>FILE = 3;</code> - */ - public static final int FILE_VALUE = 3; - - - public final int getNumber() { - return value; - } - - public static ComponentType valueOf(int value) { - switch (value) { - case 0: return PROJECT; - case 1: return MODULE; - case 2: return DIRECTORY; - case 3: return FILE; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap<ComponentType> - internalGetValueMap() { - return internalValueMap; - } - private static com.google.protobuf.Internal.EnumLiteMap<ComponentType> - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap<ComponentType>() { - public ComponentType findValueByNumber(int number) { - return ComponentType.valueOf(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - return getDescriptor().getValues().get(index); - } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { - return getDescriptor(); - } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return org.sonar.batch.protocol.Constants.getDescriptor().getEnumTypes().get(1); - } - - private static final ComponentType[] VALUES = values(); - - public static ComponentType valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - return VALUES[desc.getIndex()]; - } - - private final int index; - private final int value; - - private ComponentType(int index, int value) { - this.index = index; - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:ComponentType) - } - - /** - * Protobuf enum {@code MeasureValueType} - */ - public enum MeasureValueType - implements com.google.protobuf.ProtocolMessageEnum { - /** - * <code>INT = 0;</code> - */ - INT(0, 0), - /** - * <code>LONG = 1;</code> - */ - LONG(1, 1), - /** - * <code>DOUBLE = 2;</code> - */ - DOUBLE(2, 2), - /** - * <code>BOOLEAN = 3;</code> - */ - BOOLEAN(3, 3), - /** - * <code>STRING = 4;</code> - */ - STRING(4, 4), - ; - - /** - * <code>INT = 0;</code> - */ - public static final int INT_VALUE = 0; - /** - * <code>LONG = 1;</code> - */ - public static final int LONG_VALUE = 1; - /** - * <code>DOUBLE = 2;</code> - */ - public static final int DOUBLE_VALUE = 2; - /** - * <code>BOOLEAN = 3;</code> - */ - public static final int BOOLEAN_VALUE = 3; - /** - * <code>STRING = 4;</code> - */ - public static final int STRING_VALUE = 4; - - - public final int getNumber() { - return value; - } - - public static MeasureValueType valueOf(int value) { - switch (value) { - case 0: return INT; - case 1: return LONG; - case 2: return DOUBLE; - case 3: return BOOLEAN; - case 4: return STRING; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap<MeasureValueType> - internalGetValueMap() { - return internalValueMap; - } - private static com.google.protobuf.Internal.EnumLiteMap<MeasureValueType> - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap<MeasureValueType>() { - public MeasureValueType findValueByNumber(int number) { - return MeasureValueType.valueOf(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - return getDescriptor().getValues().get(index); - } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { - return getDescriptor(); - } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return org.sonar.batch.protocol.Constants.getDescriptor().getEnumTypes().get(2); - } - - private static final MeasureValueType[] VALUES = values(); - - public static MeasureValueType valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - return VALUES[desc.getIndex()]; - } - - private final int index; - private final int value; - - private MeasureValueType(int index, int value) { - this.index = index; - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:MeasureValueType) - } - - /** - * Protobuf enum {@code EventCategory} - * - * <pre> - * temporary enum during development of computation stack - * </pre> - */ - public enum EventCategory - implements com.google.protobuf.ProtocolMessageEnum { - /** - * <code>ALERT = 0;</code> - */ - ALERT(0, 0), - /** - * <code>PROFILE = 1;</code> - */ - PROFILE(1, 1), - ; - - /** - * <code>ALERT = 0;</code> - */ - public static final int ALERT_VALUE = 0; - /** - * <code>PROFILE = 1;</code> - */ - public static final int PROFILE_VALUE = 1; - - - public final int getNumber() { - return value; - } - - public static EventCategory valueOf(int value) { - switch (value) { - case 0: return ALERT; - case 1: return PROFILE; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap<EventCategory> - internalGetValueMap() { - return internalValueMap; - } - private static com.google.protobuf.Internal.EnumLiteMap<EventCategory> - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap<EventCategory>() { - public EventCategory findValueByNumber(int number) { - return EventCategory.valueOf(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - return getDescriptor().getValues().get(index); - } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { - return getDescriptor(); - } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return org.sonar.batch.protocol.Constants.getDescriptor().getEnumTypes().get(3); - } - - private static final EventCategory[] VALUES = values(); - - public static EventCategory valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - return VALUES[desc.getIndex()]; - } - - private final int index; - private final int value; - - private EventCategory(int index, int value) { - this.index = index; - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:EventCategory) - } - - /** - * Protobuf enum {@code ComponentLinkType} - */ - public enum ComponentLinkType - implements com.google.protobuf.ProtocolMessageEnum { - /** - * <code>HOME = 0;</code> - */ - HOME(0, 0), - /** - * <code>SCM = 1;</code> - */ - SCM(1, 1), - /** - * <code>SCM_DEV = 2;</code> - */ - SCM_DEV(2, 2), - /** - * <code>ISSUE = 3;</code> - */ - ISSUE(3, 3), - /** - * <code>CI = 4;</code> - */ - CI(4, 4), - ; - - /** - * <code>HOME = 0;</code> - */ - public static final int HOME_VALUE = 0; - /** - * <code>SCM = 1;</code> - */ - public static final int SCM_VALUE = 1; - /** - * <code>SCM_DEV = 2;</code> - */ - public static final int SCM_DEV_VALUE = 2; - /** - * <code>ISSUE = 3;</code> - */ - public static final int ISSUE_VALUE = 3; - /** - * <code>CI = 4;</code> - */ - public static final int CI_VALUE = 4; - - - public final int getNumber() { - return value; - } - - public static ComponentLinkType valueOf(int value) { - switch (value) { - case 0: return HOME; - case 1: return SCM; - case 2: return SCM_DEV; - case 3: return ISSUE; - case 4: return CI; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap<ComponentLinkType> - internalGetValueMap() { - return internalValueMap; - } - private static com.google.protobuf.Internal.EnumLiteMap<ComponentLinkType> - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap<ComponentLinkType>() { - public ComponentLinkType findValueByNumber(int number) { - return ComponentLinkType.valueOf(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - return getDescriptor().getValues().get(index); - } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { - return getDescriptor(); - } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return org.sonar.batch.protocol.Constants.getDescriptor().getEnumTypes().get(4); - } - - private static final ComponentLinkType[] VALUES = values(); - - public static ComponentLinkType valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - return VALUES[desc.getIndex()]; - } - - private final int index; - private final int value; - - private ComponentLinkType(int index, int value) { - this.index = index; - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:ComponentLinkType) - } - - /** - * Protobuf enum {@code HighlightingType} - */ - public enum HighlightingType - implements com.google.protobuf.ProtocolMessageEnum { - /** - * <code>ANNOTATION = 0;</code> - */ - ANNOTATION(0, 0), - /** - * <code>CONSTANT = 1;</code> - */ - CONSTANT(1, 1), - /** - * <code>COMMENT = 2;</code> - */ - COMMENT(2, 2), - /** - * <code>CPP_DOC = 3;</code> - */ - CPP_DOC(3, 3), - /** - * <code>STRUCTURED_COMMENT = 4;</code> - */ - STRUCTURED_COMMENT(4, 4), - /** - * <code>KEYWORD = 5;</code> - */ - KEYWORD(5, 5), - /** - * <code>HIGHLIGHTING_STRING = 6;</code> - */ - HIGHLIGHTING_STRING(6, 6), - /** - * <code>KEYWORD_LIGHT = 7;</code> - */ - KEYWORD_LIGHT(7, 7), - /** - * <code>PREPROCESS_DIRECTIVE = 8;</code> - */ - PREPROCESS_DIRECTIVE(8, 8), - ; - - /** - * <code>ANNOTATION = 0;</code> - */ - public static final int ANNOTATION_VALUE = 0; - /** - * <code>CONSTANT = 1;</code> - */ - public static final int CONSTANT_VALUE = 1; - /** - * <code>COMMENT = 2;</code> - */ - public static final int COMMENT_VALUE = 2; - /** - * <code>CPP_DOC = 3;</code> - */ - public static final int CPP_DOC_VALUE = 3; - /** - * <code>STRUCTURED_COMMENT = 4;</code> - */ - public static final int STRUCTURED_COMMENT_VALUE = 4; - /** - * <code>KEYWORD = 5;</code> - */ - public static final int KEYWORD_VALUE = 5; - /** - * <code>HIGHLIGHTING_STRING = 6;</code> - */ - public static final int HIGHLIGHTING_STRING_VALUE = 6; - /** - * <code>KEYWORD_LIGHT = 7;</code> - */ - public static final int KEYWORD_LIGHT_VALUE = 7; - /** - * <code>PREPROCESS_DIRECTIVE = 8;</code> - */ - public static final int PREPROCESS_DIRECTIVE_VALUE = 8; - - - public final int getNumber() { - return value; - } - - public static HighlightingType valueOf(int value) { - switch (value) { - case 0: return ANNOTATION; - case 1: return CONSTANT; - case 2: return COMMENT; - case 3: return CPP_DOC; - case 4: return STRUCTURED_COMMENT; - case 5: return KEYWORD; - case 6: return HIGHLIGHTING_STRING; - case 7: return KEYWORD_LIGHT; - case 8: return PREPROCESS_DIRECTIVE; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap<HighlightingType> - internalGetValueMap() { - return internalValueMap; - } - private static com.google.protobuf.Internal.EnumLiteMap<HighlightingType> - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap<HighlightingType>() { - public HighlightingType findValueByNumber(int number) { - return HighlightingType.valueOf(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - return getDescriptor().getValues().get(index); - } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { - return getDescriptor(); - } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return org.sonar.batch.protocol.Constants.getDescriptor().getEnumTypes().get(5); - } - - private static final HighlightingType[] VALUES = values(); - - public static HighlightingType valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - return VALUES[desc.getIndex()]; - } - - private final int index; - private final int value; - - private HighlightingType(int index, int value) { - this.index = index; - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:HighlightingType) - } - - /** - * Protobuf enum {@code TestStatus} - */ - public enum TestStatus - implements com.google.protobuf.ProtocolMessageEnum { - /** - * <code>OK = 1;</code> - */ - OK(0, 1), - /** - * <code>FAILURE = 2;</code> - */ - FAILURE(1, 2), - /** - * <code>ERROR = 3;</code> - */ - ERROR(2, 3), - /** - * <code>SKIPPED = 4;</code> - */ - SKIPPED(3, 4), - ; - - /** - * <code>OK = 1;</code> - */ - public static final int OK_VALUE = 1; - /** - * <code>FAILURE = 2;</code> - */ - public static final int FAILURE_VALUE = 2; - /** - * <code>ERROR = 3;</code> - */ - public static final int ERROR_VALUE = 3; - /** - * <code>SKIPPED = 4;</code> - */ - public static final int SKIPPED_VALUE = 4; - - - public final int getNumber() { - return value; - } - - public static TestStatus valueOf(int value) { - switch (value) { - case 1: return OK; - case 2: return FAILURE; - case 3: return ERROR; - case 4: return SKIPPED; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap<TestStatus> - internalGetValueMap() { - return internalValueMap; - } - private static com.google.protobuf.Internal.EnumLiteMap<TestStatus> - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap<TestStatus>() { - public TestStatus findValueByNumber(int number) { - return TestStatus.valueOf(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - return getDescriptor().getValues().get(index); - } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { - return getDescriptor(); - } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return org.sonar.batch.protocol.Constants.getDescriptor().getEnumTypes().get(6); - } - - private static final TestStatus[] VALUES = values(); - - public static TestStatus valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - return VALUES[desc.getIndex()]; - } - - private final int index; - private final int value; - - private TestStatus(int index, int value) { - this.index = index; - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:TestStatus) - } - - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n\017constants.proto*E\n\010Severity\022\010\n\004INFO\020\000\022" + - "\t\n\005MINOR\020\001\022\t\n\005MAJOR\020\002\022\014\n\010CRITICAL\020\003\022\013\n\007B" + - "LOCKER\020\004*A\n\rComponentType\022\013\n\007PROJECT\020\000\022\n" + - "\n\006MODULE\020\001\022\r\n\tDIRECTORY\020\002\022\010\n\004FILE\020\003*J\n\020M" + - "easureValueType\022\007\n\003INT\020\000\022\010\n\004LONG\020\001\022\n\n\006DO" + - "UBLE\020\002\022\013\n\007BOOLEAN\020\003\022\n\n\006STRING\020\004*\'\n\rEvent" + - "Category\022\t\n\005ALERT\020\000\022\013\n\007PROFILE\020\001*F\n\021Comp" + - "onentLinkType\022\010\n\004HOME\020\000\022\007\n\003SCM\020\001\022\013\n\007SCM_" + - "DEV\020\002\022\t\n\005ISSUE\020\003\022\006\n\002CI\020\004*\265\001\n\020Highlightin" + - "gType\022\016\n\nANNOTATION\020\000\022\014\n\010CONSTANT\020\001\022\013\n\007C", - "OMMENT\020\002\022\013\n\007CPP_DOC\020\003\022\026\n\022STRUCTURED_COMM" + - "ENT\020\004\022\013\n\007KEYWORD\020\005\022\027\n\023HIGHLIGHTING_STRIN" + - "G\020\006\022\021\n\rKEYWORD_LIGHT\020\007\022\030\n\024PREPROCESS_DIR" + - "ECTIVE\020\010*9\n\nTestStatus\022\006\n\002OK\020\001\022\013\n\007FAILUR" + - "E\020\002\022\t\n\005ERROR\020\003\022\013\n\007SKIPPED\020\004B\034\n\030org.sonar" + - ".batch.protocolH\001" - }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - }, assigner); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/input/BatchInput.java b/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/input/BatchInput.java deleted file mode 100644 index 87d2250eb70..00000000000 --- a/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/input/BatchInput.java +++ /dev/null @@ -1,2907 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: batch_input.proto - -package org.sonar.batch.protocol.input; - -public final class BatchInput { - private BatchInput() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - } - public interface ServerIssueOrBuilder extends - // @@protoc_insertion_point(interface_extends:ServerIssue) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string key = 1;</code> - */ - boolean hasKey(); - /** - * <code>optional string key = 1;</code> - */ - java.lang.String getKey(); - /** - * <code>optional string key = 1;</code> - */ - com.google.protobuf.ByteString - getKeyBytes(); - - /** - * <code>optional string module_key = 2;</code> - */ - boolean hasModuleKey(); - /** - * <code>optional string module_key = 2;</code> - */ - java.lang.String getModuleKey(); - /** - * <code>optional string module_key = 2;</code> - */ - com.google.protobuf.ByteString - getModuleKeyBytes(); - - /** - * <code>optional string path = 3;</code> - */ - boolean hasPath(); - /** - * <code>optional string path = 3;</code> - */ - java.lang.String getPath(); - /** - * <code>optional string path = 3;</code> - */ - com.google.protobuf.ByteString - getPathBytes(); - - /** - * <code>optional string rule_repository = 4;</code> - */ - boolean hasRuleRepository(); - /** - * <code>optional string rule_repository = 4;</code> - */ - java.lang.String getRuleRepository(); - /** - * <code>optional string rule_repository = 4;</code> - */ - com.google.protobuf.ByteString - getRuleRepositoryBytes(); - - /** - * <code>optional string rule_key = 5;</code> - */ - boolean hasRuleKey(); - /** - * <code>optional string rule_key = 5;</code> - */ - java.lang.String getRuleKey(); - /** - * <code>optional string rule_key = 5;</code> - */ - com.google.protobuf.ByteString - getRuleKeyBytes(); - - /** - * <code>optional int32 line = 6;</code> - */ - boolean hasLine(); - /** - * <code>optional int32 line = 6;</code> - */ - int getLine(); - - /** - * <code>optional string msg = 7;</code> - */ - boolean hasMsg(); - /** - * <code>optional string msg = 7;</code> - */ - java.lang.String getMsg(); - /** - * <code>optional string msg = 7;</code> - */ - com.google.protobuf.ByteString - getMsgBytes(); - - /** - * <code>optional .Severity severity = 8;</code> - */ - boolean hasSeverity(); - /** - * <code>optional .Severity severity = 8;</code> - */ - org.sonar.batch.protocol.Constants.Severity getSeverity(); - - /** - * <code>optional bool manual_severity = 9;</code> - */ - boolean hasManualSeverity(); - /** - * <code>optional bool manual_severity = 9;</code> - */ - boolean getManualSeverity(); - - /** - * <code>optional string resolution = 10;</code> - */ - boolean hasResolution(); - /** - * <code>optional string resolution = 10;</code> - */ - java.lang.String getResolution(); - /** - * <code>optional string resolution = 10;</code> - */ - com.google.protobuf.ByteString - getResolutionBytes(); - - /** - * <code>optional string status = 11;</code> - */ - boolean hasStatus(); - /** - * <code>optional string status = 11;</code> - */ - java.lang.String getStatus(); - /** - * <code>optional string status = 11;</code> - */ - com.google.protobuf.ByteString - getStatusBytes(); - - /** - * <code>optional string checksum = 12;</code> - */ - boolean hasChecksum(); - /** - * <code>optional string checksum = 12;</code> - */ - java.lang.String getChecksum(); - /** - * <code>optional string checksum = 12;</code> - */ - com.google.protobuf.ByteString - getChecksumBytes(); - - /** - * <code>optional string assignee_login = 13;</code> - */ - boolean hasAssigneeLogin(); - /** - * <code>optional string assignee_login = 13;</code> - */ - java.lang.String getAssigneeLogin(); - /** - * <code>optional string assignee_login = 13;</code> - */ - com.google.protobuf.ByteString - getAssigneeLoginBytes(); - - /** - * <code>optional int64 creation_date = 14;</code> - */ - boolean hasCreationDate(); - /** - * <code>optional int64 creation_date = 14;</code> - */ - long getCreationDate(); - } - /** - * Protobuf type {@code ServerIssue} - */ - public static final class ServerIssue extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:ServerIssue) - ServerIssueOrBuilder { - // Use ServerIssue.newBuilder() to construct. - private ServerIssue(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private ServerIssue() { - key_ = ""; - moduleKey_ = ""; - path_ = ""; - ruleRepository_ = ""; - ruleKey_ = ""; - line_ = 0; - msg_ = ""; - severity_ = 0; - manualSeverity_ = false; - resolution_ = ""; - status_ = ""; - checksum_ = ""; - assigneeLogin_ = ""; - creationDate_ = 0L; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ServerIssue( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - key_ = bs; - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - moduleKey_ = bs; - break; - } - case 26: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000004; - path_ = bs; - break; - } - case 34: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000008; - ruleRepository_ = bs; - break; - } - case 42: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000010; - ruleKey_ = bs; - break; - } - case 48: { - bitField0_ |= 0x00000020; - line_ = input.readInt32(); - break; - } - case 58: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000040; - msg_ = bs; - break; - } - case 64: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.Severity value = org.sonar.batch.protocol.Constants.Severity.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(8, rawValue); - } else { - bitField0_ |= 0x00000080; - severity_ = rawValue; - } - break; - } - case 72: { - bitField0_ |= 0x00000100; - manualSeverity_ = input.readBool(); - break; - } - case 82: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000200; - resolution_ = bs; - break; - } - case 90: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000400; - status_ = bs; - break; - } - case 98: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000800; - checksum_ = bs; - break; - } - case 106: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00001000; - assigneeLogin_ = bs; - break; - } - case 112: { - bitField0_ |= 0x00002000; - creationDate_ = input.readInt64(); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_ServerIssue_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_ServerIssue_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.input.BatchInput.ServerIssue.class, org.sonar.batch.protocol.input.BatchInput.ServerIssue.Builder.class); - } - - private int bitField0_; - public static final int KEY_FIELD_NUMBER = 1; - private volatile java.lang.Object key_; - /** - * <code>optional string key = 1;</code> - */ - public boolean hasKey() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string key = 1;</code> - */ - public java.lang.String getKey() { - java.lang.Object ref = key_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - key_ = s; - } - return s; - } - } - /** - * <code>optional string key = 1;</code> - */ - public com.google.protobuf.ByteString - getKeyBytes() { - java.lang.Object ref = key_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - key_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int MODULE_KEY_FIELD_NUMBER = 2; - private volatile java.lang.Object moduleKey_; - /** - * <code>optional string module_key = 2;</code> - */ - public boolean hasModuleKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string module_key = 2;</code> - */ - public java.lang.String getModuleKey() { - java.lang.Object ref = moduleKey_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - moduleKey_ = s; - } - return s; - } - } - /** - * <code>optional string module_key = 2;</code> - */ - public com.google.protobuf.ByteString - getModuleKeyBytes() { - java.lang.Object ref = moduleKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - moduleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PATH_FIELD_NUMBER = 3; - private volatile java.lang.Object path_; - /** - * <code>optional string path = 3;</code> - */ - public boolean hasPath() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string path = 3;</code> - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - path_ = s; - } - return s; - } - } - /** - * <code>optional string path = 3;</code> - */ - public com.google.protobuf.ByteString - getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int RULE_REPOSITORY_FIELD_NUMBER = 4; - private volatile java.lang.Object ruleRepository_; - /** - * <code>optional string rule_repository = 4;</code> - */ - public boolean hasRuleRepository() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional string rule_repository = 4;</code> - */ - public java.lang.String getRuleRepository() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleRepository_ = s; - } - return s; - } - } - /** - * <code>optional string rule_repository = 4;</code> - */ - public com.google.protobuf.ByteString - getRuleRepositoryBytes() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleRepository_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int RULE_KEY_FIELD_NUMBER = 5; - private volatile java.lang.Object ruleKey_; - /** - * <code>optional string rule_key = 5;</code> - */ - public boolean hasRuleKey() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional string rule_key = 5;</code> - */ - public java.lang.String getRuleKey() { - java.lang.Object ref = ruleKey_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleKey_ = s; - } - return s; - } - } - /** - * <code>optional string rule_key = 5;</code> - */ - public com.google.protobuf.ByteString - getRuleKeyBytes() { - java.lang.Object ref = ruleKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LINE_FIELD_NUMBER = 6; - private int line_; - /** - * <code>optional int32 line = 6;</code> - */ - public boolean hasLine() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional int32 line = 6;</code> - */ - public int getLine() { - return line_; - } - - public static final int MSG_FIELD_NUMBER = 7; - private volatile java.lang.Object msg_; - /** - * <code>optional string msg = 7;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional string msg = 7;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } - } - /** - * <code>optional string msg = 7;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SEVERITY_FIELD_NUMBER = 8; - private int severity_; - /** - * <code>optional .Severity severity = 8;</code> - */ - public boolean hasSeverity() { - return ((bitField0_ & 0x00000080) == 0x00000080); - } - /** - * <code>optional .Severity severity = 8;</code> - */ - public org.sonar.batch.protocol.Constants.Severity getSeverity() { - org.sonar.batch.protocol.Constants.Severity result = org.sonar.batch.protocol.Constants.Severity.valueOf(severity_); - return result == null ? org.sonar.batch.protocol.Constants.Severity.INFO : result; - } - - public static final int MANUAL_SEVERITY_FIELD_NUMBER = 9; - private boolean manualSeverity_; - /** - * <code>optional bool manual_severity = 9;</code> - */ - public boolean hasManualSeverity() { - return ((bitField0_ & 0x00000100) == 0x00000100); - } - /** - * <code>optional bool manual_severity = 9;</code> - */ - public boolean getManualSeverity() { - return manualSeverity_; - } - - public static final int RESOLUTION_FIELD_NUMBER = 10; - private volatile java.lang.Object resolution_; - /** - * <code>optional string resolution = 10;</code> - */ - public boolean hasResolution() { - return ((bitField0_ & 0x00000200) == 0x00000200); - } - /** - * <code>optional string resolution = 10;</code> - */ - public java.lang.String getResolution() { - java.lang.Object ref = resolution_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - resolution_ = s; - } - return s; - } - } - /** - * <code>optional string resolution = 10;</code> - */ - public com.google.protobuf.ByteString - getResolutionBytes() { - java.lang.Object ref = resolution_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - resolution_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int STATUS_FIELD_NUMBER = 11; - private volatile java.lang.Object status_; - /** - * <code>optional string status = 11;</code> - */ - public boolean hasStatus() { - return ((bitField0_ & 0x00000400) == 0x00000400); - } - /** - * <code>optional string status = 11;</code> - */ - public java.lang.String getStatus() { - java.lang.Object ref = status_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - status_ = s; - } - return s; - } - } - /** - * <code>optional string status = 11;</code> - */ - public com.google.protobuf.ByteString - getStatusBytes() { - java.lang.Object ref = status_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - status_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CHECKSUM_FIELD_NUMBER = 12; - private volatile java.lang.Object checksum_; - /** - * <code>optional string checksum = 12;</code> - */ - public boolean hasChecksum() { - return ((bitField0_ & 0x00000800) == 0x00000800); - } - /** - * <code>optional string checksum = 12;</code> - */ - public java.lang.String getChecksum() { - java.lang.Object ref = checksum_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - checksum_ = s; - } - return s; - } - } - /** - * <code>optional string checksum = 12;</code> - */ - public com.google.protobuf.ByteString - getChecksumBytes() { - java.lang.Object ref = checksum_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - checksum_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ASSIGNEE_LOGIN_FIELD_NUMBER = 13; - private volatile java.lang.Object assigneeLogin_; - /** - * <code>optional string assignee_login = 13;</code> - */ - public boolean hasAssigneeLogin() { - return ((bitField0_ & 0x00001000) == 0x00001000); - } - /** - * <code>optional string assignee_login = 13;</code> - */ - public java.lang.String getAssigneeLogin() { - java.lang.Object ref = assigneeLogin_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - assigneeLogin_ = s; - } - return s; - } - } - /** - * <code>optional string assignee_login = 13;</code> - */ - public com.google.protobuf.ByteString - getAssigneeLoginBytes() { - java.lang.Object ref = assigneeLogin_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - assigneeLogin_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATION_DATE_FIELD_NUMBER = 14; - private long creationDate_; - /** - * <code>optional int64 creation_date = 14;</code> - */ - public boolean hasCreationDate() { - return ((bitField0_ & 0x00002000) == 0x00002000); - } - /** - * <code>optional int64 creation_date = 14;</code> - */ - public long getCreationDate() { - return creationDate_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getKeyBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getModuleKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeBytes(3, getPathBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeBytes(4, getRuleRepositoryBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - output.writeBytes(5, getRuleKeyBytes()); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - output.writeInt32(6, line_); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - output.writeBytes(7, getMsgBytes()); - } - if (((bitField0_ & 0x00000080) == 0x00000080)) { - output.writeEnum(8, severity_); - } - if (((bitField0_ & 0x00000100) == 0x00000100)) { - output.writeBool(9, manualSeverity_); - } - if (((bitField0_ & 0x00000200) == 0x00000200)) { - output.writeBytes(10, getResolutionBytes()); - } - if (((bitField0_ & 0x00000400) == 0x00000400)) { - output.writeBytes(11, getStatusBytes()); - } - if (((bitField0_ & 0x00000800) == 0x00000800)) { - output.writeBytes(12, getChecksumBytes()); - } - if (((bitField0_ & 0x00001000) == 0x00001000)) { - output.writeBytes(13, getAssigneeLoginBytes()); - } - if (((bitField0_ & 0x00002000) == 0x00002000)) { - output.writeInt64(14, creationDate_); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getKeyBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getModuleKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(3, getPathBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(4, getRuleRepositoryBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(5, getRuleKeyBytes()); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(6, line_); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(7, getMsgBytes()); - } - if (((bitField0_ & 0x00000080) == 0x00000080)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(8, severity_); - } - if (((bitField0_ & 0x00000100) == 0x00000100)) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(9, manualSeverity_); - } - if (((bitField0_ & 0x00000200) == 0x00000200)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(10, getResolutionBytes()); - } - if (((bitField0_ & 0x00000400) == 0x00000400)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(11, getStatusBytes()); - } - if (((bitField0_ & 0x00000800) == 0x00000800)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(12, getChecksumBytes()); - } - if (((bitField0_ & 0x00001000) == 0x00001000)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(13, getAssigneeLoginBytes()); - } - if (((bitField0_ & 0x00002000) == 0x00002000)) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(14, creationDate_); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.input.BatchInput.ServerIssue prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code ServerIssue} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:ServerIssue) - org.sonar.batch.protocol.input.BatchInput.ServerIssueOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_ServerIssue_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_ServerIssue_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.input.BatchInput.ServerIssue.class, org.sonar.batch.protocol.input.BatchInput.ServerIssue.Builder.class); - } - - // Construct using org.sonar.batch.protocol.input.BatchInput.ServerIssue.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - key_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - moduleKey_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - path_ = ""; - bitField0_ = (bitField0_ & ~0x00000004); - ruleRepository_ = ""; - bitField0_ = (bitField0_ & ~0x00000008); - ruleKey_ = ""; - bitField0_ = (bitField0_ & ~0x00000010); - line_ = 0; - bitField0_ = (bitField0_ & ~0x00000020); - msg_ = ""; - bitField0_ = (bitField0_ & ~0x00000040); - severity_ = 0; - bitField0_ = (bitField0_ & ~0x00000080); - manualSeverity_ = false; - bitField0_ = (bitField0_ & ~0x00000100); - resolution_ = ""; - bitField0_ = (bitField0_ & ~0x00000200); - status_ = ""; - bitField0_ = (bitField0_ & ~0x00000400); - checksum_ = ""; - bitField0_ = (bitField0_ & ~0x00000800); - assigneeLogin_ = ""; - bitField0_ = (bitField0_ & ~0x00001000); - creationDate_ = 0L; - bitField0_ = (bitField0_ & ~0x00002000); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_ServerIssue_descriptor; - } - - public org.sonar.batch.protocol.input.BatchInput.ServerIssue getDefaultInstanceForType() { - return org.sonar.batch.protocol.input.BatchInput.ServerIssue.getDefaultInstance(); - } - - public org.sonar.batch.protocol.input.BatchInput.ServerIssue build() { - org.sonar.batch.protocol.input.BatchInput.ServerIssue result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.input.BatchInput.ServerIssue buildPartial() { - org.sonar.batch.protocol.input.BatchInput.ServerIssue result = new org.sonar.batch.protocol.input.BatchInput.ServerIssue(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.key_ = key_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.moduleKey_ = moduleKey_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.path_ = path_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.ruleRepository_ = ruleRepository_; - if (((from_bitField0_ & 0x00000010) == 0x00000010)) { - to_bitField0_ |= 0x00000010; - } - result.ruleKey_ = ruleKey_; - if (((from_bitField0_ & 0x00000020) == 0x00000020)) { - to_bitField0_ |= 0x00000020; - } - result.line_ = line_; - if (((from_bitField0_ & 0x00000040) == 0x00000040)) { - to_bitField0_ |= 0x00000040; - } - result.msg_ = msg_; - if (((from_bitField0_ & 0x00000080) == 0x00000080)) { - to_bitField0_ |= 0x00000080; - } - result.severity_ = severity_; - if (((from_bitField0_ & 0x00000100) == 0x00000100)) { - to_bitField0_ |= 0x00000100; - } - result.manualSeverity_ = manualSeverity_; - if (((from_bitField0_ & 0x00000200) == 0x00000200)) { - to_bitField0_ |= 0x00000200; - } - result.resolution_ = resolution_; - if (((from_bitField0_ & 0x00000400) == 0x00000400)) { - to_bitField0_ |= 0x00000400; - } - result.status_ = status_; - if (((from_bitField0_ & 0x00000800) == 0x00000800)) { - to_bitField0_ |= 0x00000800; - } - result.checksum_ = checksum_; - if (((from_bitField0_ & 0x00001000) == 0x00001000)) { - to_bitField0_ |= 0x00001000; - } - result.assigneeLogin_ = assigneeLogin_; - if (((from_bitField0_ & 0x00002000) == 0x00002000)) { - to_bitField0_ |= 0x00002000; - } - result.creationDate_ = creationDate_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.input.BatchInput.ServerIssue) { - return mergeFrom((org.sonar.batch.protocol.input.BatchInput.ServerIssue)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.input.BatchInput.ServerIssue other) { - if (other == org.sonar.batch.protocol.input.BatchInput.ServerIssue.getDefaultInstance()) return this; - if (other.hasKey()) { - bitField0_ |= 0x00000001; - key_ = other.key_; - onChanged(); - } - if (other.hasModuleKey()) { - bitField0_ |= 0x00000002; - moduleKey_ = other.moduleKey_; - onChanged(); - } - if (other.hasPath()) { - bitField0_ |= 0x00000004; - path_ = other.path_; - onChanged(); - } - if (other.hasRuleRepository()) { - bitField0_ |= 0x00000008; - ruleRepository_ = other.ruleRepository_; - onChanged(); - } - if (other.hasRuleKey()) { - bitField0_ |= 0x00000010; - ruleKey_ = other.ruleKey_; - onChanged(); - } - if (other.hasLine()) { - setLine(other.getLine()); - } - if (other.hasMsg()) { - bitField0_ |= 0x00000040; - msg_ = other.msg_; - onChanged(); - } - if (other.hasSeverity()) { - setSeverity(other.getSeverity()); - } - if (other.hasManualSeverity()) { - setManualSeverity(other.getManualSeverity()); - } - if (other.hasResolution()) { - bitField0_ |= 0x00000200; - resolution_ = other.resolution_; - onChanged(); - } - if (other.hasStatus()) { - bitField0_ |= 0x00000400; - status_ = other.status_; - onChanged(); - } - if (other.hasChecksum()) { - bitField0_ |= 0x00000800; - checksum_ = other.checksum_; - onChanged(); - } - if (other.hasAssigneeLogin()) { - bitField0_ |= 0x00001000; - assigneeLogin_ = other.assigneeLogin_; - onChanged(); - } - if (other.hasCreationDate()) { - setCreationDate(other.getCreationDate()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.input.BatchInput.ServerIssue parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.input.BatchInput.ServerIssue) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object key_ = ""; - /** - * <code>optional string key = 1;</code> - */ - public boolean hasKey() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string key = 1;</code> - */ - public java.lang.String getKey() { - java.lang.Object ref = key_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - key_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string key = 1;</code> - */ - public com.google.protobuf.ByteString - getKeyBytes() { - java.lang.Object ref = key_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - key_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string key = 1;</code> - */ - public Builder setKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - key_ = value; - onChanged(); - return this; - } - /** - * <code>optional string key = 1;</code> - */ - public Builder clearKey() { - bitField0_ = (bitField0_ & ~0x00000001); - key_ = getDefaultInstance().getKey(); - onChanged(); - return this; - } - /** - * <code>optional string key = 1;</code> - */ - public Builder setKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - key_ = value; - onChanged(); - return this; - } - - private java.lang.Object moduleKey_ = ""; - /** - * <code>optional string module_key = 2;</code> - */ - public boolean hasModuleKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string module_key = 2;</code> - */ - public java.lang.String getModuleKey() { - java.lang.Object ref = moduleKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - moduleKey_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string module_key = 2;</code> - */ - public com.google.protobuf.ByteString - getModuleKeyBytes() { - java.lang.Object ref = moduleKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - moduleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string module_key = 2;</code> - */ - public Builder setModuleKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - moduleKey_ = value; - onChanged(); - return this; - } - /** - * <code>optional string module_key = 2;</code> - */ - public Builder clearModuleKey() { - bitField0_ = (bitField0_ & ~0x00000002); - moduleKey_ = getDefaultInstance().getModuleKey(); - onChanged(); - return this; - } - /** - * <code>optional string module_key = 2;</code> - */ - public Builder setModuleKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - moduleKey_ = value; - onChanged(); - return this; - } - - private java.lang.Object path_ = ""; - /** - * <code>optional string path = 3;</code> - */ - public boolean hasPath() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string path = 3;</code> - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - path_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string path = 3;</code> - */ - public com.google.protobuf.ByteString - getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string path = 3;</code> - */ - public Builder setPath( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - path_ = value; - onChanged(); - return this; - } - /** - * <code>optional string path = 3;</code> - */ - public Builder clearPath() { - bitField0_ = (bitField0_ & ~0x00000004); - path_ = getDefaultInstance().getPath(); - onChanged(); - return this; - } - /** - * <code>optional string path = 3;</code> - */ - public Builder setPathBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - path_ = value; - onChanged(); - return this; - } - - private java.lang.Object ruleRepository_ = ""; - /** - * <code>optional string rule_repository = 4;</code> - */ - public boolean hasRuleRepository() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional string rule_repository = 4;</code> - */ - public java.lang.String getRuleRepository() { - java.lang.Object ref = ruleRepository_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleRepository_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string rule_repository = 4;</code> - */ - public com.google.protobuf.ByteString - getRuleRepositoryBytes() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleRepository_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string rule_repository = 4;</code> - */ - public Builder setRuleRepository( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - ruleRepository_ = value; - onChanged(); - return this; - } - /** - * <code>optional string rule_repository = 4;</code> - */ - public Builder clearRuleRepository() { - bitField0_ = (bitField0_ & ~0x00000008); - ruleRepository_ = getDefaultInstance().getRuleRepository(); - onChanged(); - return this; - } - /** - * <code>optional string rule_repository = 4;</code> - */ - public Builder setRuleRepositoryBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - ruleRepository_ = value; - onChanged(); - return this; - } - - private java.lang.Object ruleKey_ = ""; - /** - * <code>optional string rule_key = 5;</code> - */ - public boolean hasRuleKey() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional string rule_key = 5;</code> - */ - public java.lang.String getRuleKey() { - java.lang.Object ref = ruleKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleKey_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string rule_key = 5;</code> - */ - public com.google.protobuf.ByteString - getRuleKeyBytes() { - java.lang.Object ref = ruleKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string rule_key = 5;</code> - */ - public Builder setRuleKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000010; - ruleKey_ = value; - onChanged(); - return this; - } - /** - * <code>optional string rule_key = 5;</code> - */ - public Builder clearRuleKey() { - bitField0_ = (bitField0_ & ~0x00000010); - ruleKey_ = getDefaultInstance().getRuleKey(); - onChanged(); - return this; - } - /** - * <code>optional string rule_key = 5;</code> - */ - public Builder setRuleKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000010; - ruleKey_ = value; - onChanged(); - return this; - } - - private int line_ ; - /** - * <code>optional int32 line = 6;</code> - */ - public boolean hasLine() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional int32 line = 6;</code> - */ - public int getLine() { - return line_; - } - /** - * <code>optional int32 line = 6;</code> - */ - public Builder setLine(int value) { - bitField0_ |= 0x00000020; - line_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 line = 6;</code> - */ - public Builder clearLine() { - bitField0_ = (bitField0_ & ~0x00000020); - line_ = 0; - onChanged(); - return this; - } - - private java.lang.Object msg_ = ""; - /** - * <code>optional string msg = 7;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional string msg = 7;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string msg = 7;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string msg = 7;</code> - */ - public Builder setMsg( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000040; - msg_ = value; - onChanged(); - return this; - } - /** - * <code>optional string msg = 7;</code> - */ - public Builder clearMsg() { - bitField0_ = (bitField0_ & ~0x00000040); - msg_ = getDefaultInstance().getMsg(); - onChanged(); - return this; - } - /** - * <code>optional string msg = 7;</code> - */ - public Builder setMsgBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000040; - msg_ = value; - onChanged(); - return this; - } - - private int severity_ = 0; - /** - * <code>optional .Severity severity = 8;</code> - */ - public boolean hasSeverity() { - return ((bitField0_ & 0x00000080) == 0x00000080); - } - /** - * <code>optional .Severity severity = 8;</code> - */ - public org.sonar.batch.protocol.Constants.Severity getSeverity() { - org.sonar.batch.protocol.Constants.Severity result = org.sonar.batch.protocol.Constants.Severity.valueOf(severity_); - return result == null ? org.sonar.batch.protocol.Constants.Severity.INFO : result; - } - /** - * <code>optional .Severity severity = 8;</code> - */ - public Builder setSeverity(org.sonar.batch.protocol.Constants.Severity value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000080; - severity_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .Severity severity = 8;</code> - */ - public Builder clearSeverity() { - bitField0_ = (bitField0_ & ~0x00000080); - severity_ = 0; - onChanged(); - return this; - } - - private boolean manualSeverity_ ; - /** - * <code>optional bool manual_severity = 9;</code> - */ - public boolean hasManualSeverity() { - return ((bitField0_ & 0x00000100) == 0x00000100); - } - /** - * <code>optional bool manual_severity = 9;</code> - */ - public boolean getManualSeverity() { - return manualSeverity_; - } - /** - * <code>optional bool manual_severity = 9;</code> - */ - public Builder setManualSeverity(boolean value) { - bitField0_ |= 0x00000100; - manualSeverity_ = value; - onChanged(); - return this; - } - /** - * <code>optional bool manual_severity = 9;</code> - */ - public Builder clearManualSeverity() { - bitField0_ = (bitField0_ & ~0x00000100); - manualSeverity_ = false; - onChanged(); - return this; - } - - private java.lang.Object resolution_ = ""; - /** - * <code>optional string resolution = 10;</code> - */ - public boolean hasResolution() { - return ((bitField0_ & 0x00000200) == 0x00000200); - } - /** - * <code>optional string resolution = 10;</code> - */ - public java.lang.String getResolution() { - java.lang.Object ref = resolution_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - resolution_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string resolution = 10;</code> - */ - public com.google.protobuf.ByteString - getResolutionBytes() { - java.lang.Object ref = resolution_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - resolution_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string resolution = 10;</code> - */ - public Builder setResolution( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000200; - resolution_ = value; - onChanged(); - return this; - } - /** - * <code>optional string resolution = 10;</code> - */ - public Builder clearResolution() { - bitField0_ = (bitField0_ & ~0x00000200); - resolution_ = getDefaultInstance().getResolution(); - onChanged(); - return this; - } - /** - * <code>optional string resolution = 10;</code> - */ - public Builder setResolutionBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000200; - resolution_ = value; - onChanged(); - return this; - } - - private java.lang.Object status_ = ""; - /** - * <code>optional string status = 11;</code> - */ - public boolean hasStatus() { - return ((bitField0_ & 0x00000400) == 0x00000400); - } - /** - * <code>optional string status = 11;</code> - */ - public java.lang.String getStatus() { - java.lang.Object ref = status_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - status_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string status = 11;</code> - */ - public com.google.protobuf.ByteString - getStatusBytes() { - java.lang.Object ref = status_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - status_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string status = 11;</code> - */ - public Builder setStatus( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000400; - status_ = value; - onChanged(); - return this; - } - /** - * <code>optional string status = 11;</code> - */ - public Builder clearStatus() { - bitField0_ = (bitField0_ & ~0x00000400); - status_ = getDefaultInstance().getStatus(); - onChanged(); - return this; - } - /** - * <code>optional string status = 11;</code> - */ - public Builder setStatusBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000400; - status_ = value; - onChanged(); - return this; - } - - private java.lang.Object checksum_ = ""; - /** - * <code>optional string checksum = 12;</code> - */ - public boolean hasChecksum() { - return ((bitField0_ & 0x00000800) == 0x00000800); - } - /** - * <code>optional string checksum = 12;</code> - */ - public java.lang.String getChecksum() { - java.lang.Object ref = checksum_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - checksum_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string checksum = 12;</code> - */ - public com.google.protobuf.ByteString - getChecksumBytes() { - java.lang.Object ref = checksum_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - checksum_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string checksum = 12;</code> - */ - public Builder setChecksum( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000800; - checksum_ = value; - onChanged(); - return this; - } - /** - * <code>optional string checksum = 12;</code> - */ - public Builder clearChecksum() { - bitField0_ = (bitField0_ & ~0x00000800); - checksum_ = getDefaultInstance().getChecksum(); - onChanged(); - return this; - } - /** - * <code>optional string checksum = 12;</code> - */ - public Builder setChecksumBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000800; - checksum_ = value; - onChanged(); - return this; - } - - private java.lang.Object assigneeLogin_ = ""; - /** - * <code>optional string assignee_login = 13;</code> - */ - public boolean hasAssigneeLogin() { - return ((bitField0_ & 0x00001000) == 0x00001000); - } - /** - * <code>optional string assignee_login = 13;</code> - */ - public java.lang.String getAssigneeLogin() { - java.lang.Object ref = assigneeLogin_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - assigneeLogin_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string assignee_login = 13;</code> - */ - public com.google.protobuf.ByteString - getAssigneeLoginBytes() { - java.lang.Object ref = assigneeLogin_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - assigneeLogin_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string assignee_login = 13;</code> - */ - public Builder setAssigneeLogin( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00001000; - assigneeLogin_ = value; - onChanged(); - return this; - } - /** - * <code>optional string assignee_login = 13;</code> - */ - public Builder clearAssigneeLogin() { - bitField0_ = (bitField0_ & ~0x00001000); - assigneeLogin_ = getDefaultInstance().getAssigneeLogin(); - onChanged(); - return this; - } - /** - * <code>optional string assignee_login = 13;</code> - */ - public Builder setAssigneeLoginBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00001000; - assigneeLogin_ = value; - onChanged(); - return this; - } - - private long creationDate_ ; - /** - * <code>optional int64 creation_date = 14;</code> - */ - public boolean hasCreationDate() { - return ((bitField0_ & 0x00002000) == 0x00002000); - } - /** - * <code>optional int64 creation_date = 14;</code> - */ - public long getCreationDate() { - return creationDate_; - } - /** - * <code>optional int64 creation_date = 14;</code> - */ - public Builder setCreationDate(long value) { - bitField0_ |= 0x00002000; - creationDate_ = value; - onChanged(); - return this; - } - /** - * <code>optional int64 creation_date = 14;</code> - */ - public Builder clearCreationDate() { - bitField0_ = (bitField0_ & ~0x00002000); - creationDate_ = 0L; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:ServerIssue) - } - - // @@protoc_insertion_point(class_scope:ServerIssue) - private static final org.sonar.batch.protocol.input.BatchInput.ServerIssue DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.input.BatchInput.ServerIssue(); - } - - public static org.sonar.batch.protocol.input.BatchInput.ServerIssue getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<ServerIssue> PARSER = - new com.google.protobuf.AbstractParser<ServerIssue>() { - public ServerIssue parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new ServerIssue(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<ServerIssue> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.input.BatchInput.ServerIssue getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface UserOrBuilder extends - // @@protoc_insertion_point(interface_extends:User) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string login = 1;</code> - */ - boolean hasLogin(); - /** - * <code>optional string login = 1;</code> - */ - java.lang.String getLogin(); - /** - * <code>optional string login = 1;</code> - */ - com.google.protobuf.ByteString - getLoginBytes(); - - /** - * <code>optional string name = 2;</code> - */ - boolean hasName(); - /** - * <code>optional string name = 2;</code> - */ - java.lang.String getName(); - /** - * <code>optional string name = 2;</code> - */ - com.google.protobuf.ByteString - getNameBytes(); - } - /** - * Protobuf type {@code User} - */ - public static final class User extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:User) - UserOrBuilder { - // Use User.newBuilder() to construct. - private User(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private User() { - login_ = ""; - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private User( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - login_ = bs; - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - name_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_User_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_User_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.input.BatchInput.User.class, org.sonar.batch.protocol.input.BatchInput.User.Builder.class); - } - - private int bitField0_; - public static final int LOGIN_FIELD_NUMBER = 1; - private volatile java.lang.Object login_; - /** - * <code>optional string login = 1;</code> - */ - public boolean hasLogin() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string login = 1;</code> - */ - public java.lang.String getLogin() { - java.lang.Object ref = login_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - login_ = s; - } - return s; - } - } - /** - * <code>optional string login = 1;</code> - */ - public com.google.protobuf.ByteString - getLoginBytes() { - java.lang.Object ref = login_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - login_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object name_; - /** - * <code>optional string name = 2;</code> - */ - public boolean hasName() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string name = 2;</code> - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - name_ = s; - } - return s; - } - } - /** - * <code>optional string name = 2;</code> - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getLoginBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getNameBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getLoginBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getNameBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.input.BatchInput.User parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.input.BatchInput.User prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code User} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:User) - org.sonar.batch.protocol.input.BatchInput.UserOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_User_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_User_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.input.BatchInput.User.class, org.sonar.batch.protocol.input.BatchInput.User.Builder.class); - } - - // Construct using org.sonar.batch.protocol.input.BatchInput.User.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - login_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - name_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.input.BatchInput.internal_static_User_descriptor; - } - - public org.sonar.batch.protocol.input.BatchInput.User getDefaultInstanceForType() { - return org.sonar.batch.protocol.input.BatchInput.User.getDefaultInstance(); - } - - public org.sonar.batch.protocol.input.BatchInput.User build() { - org.sonar.batch.protocol.input.BatchInput.User result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.input.BatchInput.User buildPartial() { - org.sonar.batch.protocol.input.BatchInput.User result = new org.sonar.batch.protocol.input.BatchInput.User(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.login_ = login_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.name_ = name_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.input.BatchInput.User) { - return mergeFrom((org.sonar.batch.protocol.input.BatchInput.User)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.input.BatchInput.User other) { - if (other == org.sonar.batch.protocol.input.BatchInput.User.getDefaultInstance()) return this; - if (other.hasLogin()) { - bitField0_ |= 0x00000001; - login_ = other.login_; - onChanged(); - } - if (other.hasName()) { - bitField0_ |= 0x00000002; - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.input.BatchInput.User parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.input.BatchInput.User) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object login_ = ""; - /** - * <code>optional string login = 1;</code> - */ - public boolean hasLogin() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string login = 1;</code> - */ - public java.lang.String getLogin() { - java.lang.Object ref = login_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - login_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string login = 1;</code> - */ - public com.google.protobuf.ByteString - getLoginBytes() { - java.lang.Object ref = login_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - login_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string login = 1;</code> - */ - public Builder setLogin( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - login_ = value; - onChanged(); - return this; - } - /** - * <code>optional string login = 1;</code> - */ - public Builder clearLogin() { - bitField0_ = (bitField0_ & ~0x00000001); - login_ = getDefaultInstance().getLogin(); - onChanged(); - return this; - } - /** - * <code>optional string login = 1;</code> - */ - public Builder setLoginBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - login_ = value; - onChanged(); - return this; - } - - private java.lang.Object name_ = ""; - /** - * <code>optional string name = 2;</code> - */ - public boolean hasName() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string name = 2;</code> - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - name_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string name = 2;</code> - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string name = 2;</code> - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - name_ = value; - onChanged(); - return this; - } - /** - * <code>optional string name = 2;</code> - */ - public Builder clearName() { - bitField0_ = (bitField0_ & ~0x00000002); - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * <code>optional string name = 2;</code> - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - name_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:User) - } - - // @@protoc_insertion_point(class_scope:User) - private static final org.sonar.batch.protocol.input.BatchInput.User DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.input.BatchInput.User(); - } - - public static org.sonar.batch.protocol.input.BatchInput.User getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<User> PARSER = - new com.google.protobuf.AbstractParser<User>() { - public User parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new User(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<User> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.input.BatchInput.User getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private static com.google.protobuf.Descriptors.Descriptor - internal_static_ServerIssue_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_ServerIssue_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_User_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_User_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n\021batch_input.proto\032\017constants.proto\"\235\002\n" + - "\013ServerIssue\022\013\n\003key\030\001 \001(\t\022\022\n\nmodule_key\030" + - "\002 \001(\t\022\014\n\004path\030\003 \001(\t\022\027\n\017rule_repository\030\004" + - " \001(\t\022\020\n\010rule_key\030\005 \001(\t\022\014\n\004line\030\006 \001(\005\022\013\n\003" + - "msg\030\007 \001(\t\022\033\n\010severity\030\010 \001(\0162\t.Severity\022\027" + - "\n\017manual_severity\030\t \001(\010\022\022\n\nresolution\030\n " + - "\001(\t\022\016\n\006status\030\013 \001(\t\022\020\n\010checksum\030\014 \001(\t\022\026\n" + - "\016assignee_login\030\r \001(\t\022\025\n\rcreation_date\030\016" + - " \001(\003\"#\n\004User\022\r\n\005login\030\001 \001(\t\022\014\n\004name\030\002 \001(" + - "\tB\"\n\036org.sonar.batch.protocol.inputH\001" - }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - org.sonar.batch.protocol.Constants.getDescriptor(), - }, assigner); - internal_static_ServerIssue_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_ServerIssue_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_ServerIssue_descriptor, - new java.lang.String[] { "Key", "ModuleKey", "Path", "RuleRepository", "RuleKey", "Line", "Msg", "Severity", "ManualSeverity", "Resolution", "Status", "Checksum", "AssigneeLogin", "CreationDate", }); - internal_static_User_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_User_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_User_descriptor, - new java.lang.String[] { "Login", "Name", }); - org.sonar.batch.protocol.Constants.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/output/BatchReport.java b/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/output/BatchReport.java deleted file mode 100644 index deaa30b4aa8..00000000000 --- a/sonar-batch-protocol/src/main/gen-java/org/sonar/batch/protocol/output/BatchReport.java +++ /dev/null @@ -1,18993 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: batch_report.proto - -package org.sonar.batch.protocol.output; - -public final class BatchReport { - private BatchReport() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - } - public interface MetadataOrBuilder extends - // @@protoc_insertion_point(interface_extends:Metadata) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int64 analysis_date = 1;</code> - */ - boolean hasAnalysisDate(); - /** - * <code>optional int64 analysis_date = 1;</code> - */ - long getAnalysisDate(); - - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - boolean hasProjectKey(); - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - java.lang.String getProjectKey(); - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - com.google.protobuf.ByteString - getProjectKeyBytes(); - - /** - * <code>optional string branch = 3;</code> - */ - boolean hasBranch(); - /** - * <code>optional string branch = 3;</code> - */ - java.lang.String getBranch(); - /** - * <code>optional string branch = 3;</code> - */ - com.google.protobuf.ByteString - getBranchBytes(); - - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - boolean hasRootComponentRef(); - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - int getRootComponentRef(); - } - /** - * Protobuf type {@code Metadata} - */ - public static final class Metadata extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Metadata) - MetadataOrBuilder { - // Use Metadata.newBuilder() to construct. - private Metadata(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Metadata() { - analysisDate_ = 0L; - projectKey_ = ""; - branch_ = ""; - rootComponentRef_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Metadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - analysisDate_ = input.readInt64(); - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - projectKey_ = bs; - break; - } - case 26: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000004; - branch_ = bs; - break; - } - case 32: { - bitField0_ |= 0x00000008; - rootComponentRef_ = input.readInt32(); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Metadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Metadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Metadata.class, org.sonar.batch.protocol.output.BatchReport.Metadata.Builder.class); - } - - private int bitField0_; - public static final int ANALYSIS_DATE_FIELD_NUMBER = 1; - private long analysisDate_; - /** - * <code>optional int64 analysis_date = 1;</code> - */ - public boolean hasAnalysisDate() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int64 analysis_date = 1;</code> - */ - public long getAnalysisDate() { - return analysisDate_; - } - - public static final int PROJECT_KEY_FIELD_NUMBER = 2; - private volatile java.lang.Object projectKey_; - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public boolean hasProjectKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public java.lang.String getProjectKey() { - java.lang.Object ref = projectKey_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - projectKey_ = s; - } - return s; - } - } - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public com.google.protobuf.ByteString - getProjectKeyBytes() { - java.lang.Object ref = projectKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - projectKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int BRANCH_FIELD_NUMBER = 3; - private volatile java.lang.Object branch_; - /** - * <code>optional string branch = 3;</code> - */ - public boolean hasBranch() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string branch = 3;</code> - */ - public java.lang.String getBranch() { - java.lang.Object ref = branch_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - branch_ = s; - } - return s; - } - } - /** - * <code>optional string branch = 3;</code> - */ - public com.google.protobuf.ByteString - getBranchBytes() { - java.lang.Object ref = branch_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - branch_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ROOT_COMPONENT_REF_FIELD_NUMBER = 4; - private int rootComponentRef_; - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - public boolean hasRootComponentRef() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - public int getRootComponentRef() { - return rootComponentRef_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt64(1, analysisDate_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getProjectKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeBytes(3, getBranchBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeInt32(4, rootComponentRef_); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, analysisDate_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getProjectKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(3, getBranchBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(4, rootComponentRef_); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Metadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Metadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Metadata} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Metadata) - org.sonar.batch.protocol.output.BatchReport.MetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Metadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Metadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Metadata.class, org.sonar.batch.protocol.output.BatchReport.Metadata.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Metadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - analysisDate_ = 0L; - bitField0_ = (bitField0_ & ~0x00000001); - projectKey_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - branch_ = ""; - bitField0_ = (bitField0_ & ~0x00000004); - rootComponentRef_ = 0; - bitField0_ = (bitField0_ & ~0x00000008); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Metadata_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Metadata getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Metadata.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Metadata build() { - org.sonar.batch.protocol.output.BatchReport.Metadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Metadata buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Metadata result = new org.sonar.batch.protocol.output.BatchReport.Metadata(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.analysisDate_ = analysisDate_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.projectKey_ = projectKey_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.branch_ = branch_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.rootComponentRef_ = rootComponentRef_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Metadata) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Metadata)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Metadata other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Metadata.getDefaultInstance()) return this; - if (other.hasAnalysisDate()) { - setAnalysisDate(other.getAnalysisDate()); - } - if (other.hasProjectKey()) { - bitField0_ |= 0x00000002; - projectKey_ = other.projectKey_; - onChanged(); - } - if (other.hasBranch()) { - bitField0_ |= 0x00000004; - branch_ = other.branch_; - onChanged(); - } - if (other.hasRootComponentRef()) { - setRootComponentRef(other.getRootComponentRef()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Metadata parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Metadata) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private long analysisDate_ ; - /** - * <code>optional int64 analysis_date = 1;</code> - */ - public boolean hasAnalysisDate() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int64 analysis_date = 1;</code> - */ - public long getAnalysisDate() { - return analysisDate_; - } - /** - * <code>optional int64 analysis_date = 1;</code> - */ - public Builder setAnalysisDate(long value) { - bitField0_ |= 0x00000001; - analysisDate_ = value; - onChanged(); - return this; - } - /** - * <code>optional int64 analysis_date = 1;</code> - */ - public Builder clearAnalysisDate() { - bitField0_ = (bitField0_ & ~0x00000001); - analysisDate_ = 0L; - onChanged(); - return this; - } - - private java.lang.Object projectKey_ = ""; - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public boolean hasProjectKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public java.lang.String getProjectKey() { - java.lang.Object ref = projectKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - projectKey_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public com.google.protobuf.ByteString - getProjectKeyBytes() { - java.lang.Object ref = projectKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - projectKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public Builder setProjectKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - projectKey_ = value; - onChanged(); - return this; - } - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public Builder clearProjectKey() { - bitField0_ = (bitField0_ & ~0x00000002); - projectKey_ = getDefaultInstance().getProjectKey(); - onChanged(); - return this; - } - /** - * <code>optional string project_key = 2;</code> - * - * <pre> - * TODO should we keep this project_key here or not ? Because it's a duplication of Component.key - * </pre> - */ - public Builder setProjectKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - projectKey_ = value; - onChanged(); - return this; - } - - private java.lang.Object branch_ = ""; - /** - * <code>optional string branch = 3;</code> - */ - public boolean hasBranch() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string branch = 3;</code> - */ - public java.lang.String getBranch() { - java.lang.Object ref = branch_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - branch_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string branch = 3;</code> - */ - public com.google.protobuf.ByteString - getBranchBytes() { - java.lang.Object ref = branch_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - branch_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string branch = 3;</code> - */ - public Builder setBranch( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - branch_ = value; - onChanged(); - return this; - } - /** - * <code>optional string branch = 3;</code> - */ - public Builder clearBranch() { - bitField0_ = (bitField0_ & ~0x00000004); - branch_ = getDefaultInstance().getBranch(); - onChanged(); - return this; - } - /** - * <code>optional string branch = 3;</code> - */ - public Builder setBranchBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - branch_ = value; - onChanged(); - return this; - } - - private int rootComponentRef_ ; - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - public boolean hasRootComponentRef() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - public int getRootComponentRef() { - return rootComponentRef_; - } - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - public Builder setRootComponentRef(int value) { - bitField0_ |= 0x00000008; - rootComponentRef_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 root_component_ref = 4;</code> - */ - public Builder clearRootComponentRef() { - bitField0_ = (bitField0_ & ~0x00000008); - rootComponentRef_ = 0; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Metadata) - } - - // @@protoc_insertion_point(class_scope:Metadata) - private static final org.sonar.batch.protocol.output.BatchReport.Metadata DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Metadata(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Metadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Metadata> PARSER = - new com.google.protobuf.AbstractParser<Metadata>() { - public Metadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Metadata(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Metadata> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Metadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ActiveRuleOrBuilder extends - // @@protoc_insertion_point(interface_extends:ActiveRule) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string rule_repository = 1;</code> - */ - boolean hasRuleRepository(); - /** - * <code>optional string rule_repository = 1;</code> - */ - java.lang.String getRuleRepository(); - /** - * <code>optional string rule_repository = 1;</code> - */ - com.google.protobuf.ByteString - getRuleRepositoryBytes(); - - /** - * <code>optional string rule_key = 2;</code> - */ - boolean hasRuleKey(); - /** - * <code>optional string rule_key = 2;</code> - */ - java.lang.String getRuleKey(); - /** - * <code>optional string rule_key = 2;</code> - */ - com.google.protobuf.ByteString - getRuleKeyBytes(); - - /** - * <code>optional .Severity severity = 3;</code> - */ - boolean hasSeverity(); - /** - * <code>optional .Severity severity = 3;</code> - */ - org.sonar.batch.protocol.Constants.Severity getSeverity(); - - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam> - getParamList(); - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam getParam(int index); - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - int getParamCount(); - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder> - getParamOrBuilderList(); - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder getParamOrBuilder( - int index); - } - /** - * Protobuf type {@code ActiveRule} - */ - public static final class ActiveRule extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:ActiveRule) - ActiveRuleOrBuilder { - // Use ActiveRule.newBuilder() to construct. - private ActiveRule(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private ActiveRule() { - ruleRepository_ = ""; - ruleKey_ = ""; - severity_ = 0; - param_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ActiveRule( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - ruleRepository_ = bs; - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - ruleKey_ = bs; - break; - } - case 24: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.Severity value = org.sonar.batch.protocol.Constants.Severity.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(3, rawValue); - } else { - bitField0_ |= 0x00000004; - severity_ = rawValue; - } - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - param_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam>(); - mutable_bitField0_ |= 0x00000008; - } - param_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.PARSER, extensionRegistry)); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - param_ = java.util.Collections.unmodifiableList(param_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.ActiveRule.class, org.sonar.batch.protocol.output.BatchReport.ActiveRule.Builder.class); - } - - public interface ActiveRuleParamOrBuilder extends - // @@protoc_insertion_point(interface_extends:ActiveRule.ActiveRuleParam) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string key = 1;</code> - */ - boolean hasKey(); - /** - * <code>optional string key = 1;</code> - */ - java.lang.String getKey(); - /** - * <code>optional string key = 1;</code> - */ - com.google.protobuf.ByteString - getKeyBytes(); - - /** - * <code>optional string value = 2;</code> - */ - boolean hasValue(); - /** - * <code>optional string value = 2;</code> - */ - java.lang.String getValue(); - /** - * <code>optional string value = 2;</code> - */ - com.google.protobuf.ByteString - getValueBytes(); - } - /** - * Protobuf type {@code ActiveRule.ActiveRuleParam} - * - * <pre> - * TODO replace by map - * </pre> - */ - public static final class ActiveRuleParam extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:ActiveRule.ActiveRuleParam) - ActiveRuleParamOrBuilder { - // Use ActiveRuleParam.newBuilder() to construct. - private ActiveRuleParam(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private ActiveRuleParam() { - key_ = ""; - value_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ActiveRuleParam( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - key_ = bs; - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - value_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_ActiveRuleParam_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_ActiveRuleParam_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.class, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder.class); - } - - private int bitField0_; - public static final int KEY_FIELD_NUMBER = 1; - private volatile java.lang.Object key_; - /** - * <code>optional string key = 1;</code> - */ - public boolean hasKey() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string key = 1;</code> - */ - public java.lang.String getKey() { - java.lang.Object ref = key_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - key_ = s; - } - return s; - } - } - /** - * <code>optional string key = 1;</code> - */ - public com.google.protobuf.ByteString - getKeyBytes() { - java.lang.Object ref = key_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - key_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int VALUE_FIELD_NUMBER = 2; - private volatile java.lang.Object value_; - /** - * <code>optional string value = 2;</code> - */ - public boolean hasValue() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string value = 2;</code> - */ - public java.lang.String getValue() { - java.lang.Object ref = value_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - value_ = s; - } - return s; - } - } - /** - * <code>optional string value = 2;</code> - */ - public com.google.protobuf.ByteString - getValueBytes() { - java.lang.Object ref = value_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - value_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getKeyBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getValueBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getKeyBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getValueBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code ActiveRule.ActiveRuleParam} - * - * <pre> - * TODO replace by map - * </pre> - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:ActiveRule.ActiveRuleParam) - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_ActiveRuleParam_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_ActiveRuleParam_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.class, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - key_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - value_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_ActiveRuleParam_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam build() { - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam buildPartial() { - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam result = new org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.key_ = key_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.value_ = value_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam other) { - if (other == org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.getDefaultInstance()) return this; - if (other.hasKey()) { - bitField0_ |= 0x00000001; - key_ = other.key_; - onChanged(); - } - if (other.hasValue()) { - bitField0_ |= 0x00000002; - value_ = other.value_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object key_ = ""; - /** - * <code>optional string key = 1;</code> - */ - public boolean hasKey() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string key = 1;</code> - */ - public java.lang.String getKey() { - java.lang.Object ref = key_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - key_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string key = 1;</code> - */ - public com.google.protobuf.ByteString - getKeyBytes() { - java.lang.Object ref = key_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - key_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string key = 1;</code> - */ - public Builder setKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - key_ = value; - onChanged(); - return this; - } - /** - * <code>optional string key = 1;</code> - */ - public Builder clearKey() { - bitField0_ = (bitField0_ & ~0x00000001); - key_ = getDefaultInstance().getKey(); - onChanged(); - return this; - } - /** - * <code>optional string key = 1;</code> - */ - public Builder setKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - key_ = value; - onChanged(); - return this; - } - - private java.lang.Object value_ = ""; - /** - * <code>optional string value = 2;</code> - */ - public boolean hasValue() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string value = 2;</code> - */ - public java.lang.String getValue() { - java.lang.Object ref = value_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - value_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string value = 2;</code> - */ - public com.google.protobuf.ByteString - getValueBytes() { - java.lang.Object ref = value_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - value_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string value = 2;</code> - */ - public Builder setValue( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - value_ = value; - onChanged(); - return this; - } - /** - * <code>optional string value = 2;</code> - */ - public Builder clearValue() { - bitField0_ = (bitField0_ & ~0x00000002); - value_ = getDefaultInstance().getValue(); - onChanged(); - return this; - } - /** - * <code>optional string value = 2;</code> - */ - public Builder setValueBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - value_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:ActiveRule.ActiveRuleParam) - } - - // @@protoc_insertion_point(class_scope:ActiveRule.ActiveRuleParam) - private static final org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam(); - } - - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<ActiveRuleParam> PARSER = - new com.google.protobuf.AbstractParser<ActiveRuleParam>() { - public ActiveRuleParam parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new ActiveRuleParam(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<ActiveRuleParam> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int bitField0_; - public static final int RULE_REPOSITORY_FIELD_NUMBER = 1; - private volatile java.lang.Object ruleRepository_; - /** - * <code>optional string rule_repository = 1;</code> - */ - public boolean hasRuleRepository() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public java.lang.String getRuleRepository() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleRepository_ = s; - } - return s; - } - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public com.google.protobuf.ByteString - getRuleRepositoryBytes() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleRepository_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int RULE_KEY_FIELD_NUMBER = 2; - private volatile java.lang.Object ruleKey_; - /** - * <code>optional string rule_key = 2;</code> - */ - public boolean hasRuleKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string rule_key = 2;</code> - */ - public java.lang.String getRuleKey() { - java.lang.Object ref = ruleKey_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleKey_ = s; - } - return s; - } - } - /** - * <code>optional string rule_key = 2;</code> - */ - public com.google.protobuf.ByteString - getRuleKeyBytes() { - java.lang.Object ref = ruleKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SEVERITY_FIELD_NUMBER = 3; - private int severity_; - /** - * <code>optional .Severity severity = 3;</code> - */ - public boolean hasSeverity() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional .Severity severity = 3;</code> - */ - public org.sonar.batch.protocol.Constants.Severity getSeverity() { - org.sonar.batch.protocol.Constants.Severity result = org.sonar.batch.protocol.Constants.Severity.valueOf(severity_); - return result == null ? org.sonar.batch.protocol.Constants.Severity.INFO : result; - } - - public static final int PARAM_FIELD_NUMBER = 4; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam> param_; - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam> getParamList() { - return param_; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder> - getParamOrBuilderList() { - return param_; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public int getParamCount() { - return param_.size(); - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam getParam(int index) { - return param_.get(index); - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder getParamOrBuilder( - int index) { - return param_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getRuleRepositoryBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getRuleKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeEnum(3, severity_); - } - for (int i = 0; i < param_.size(); i++) { - output.writeMessage(4, param_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getRuleRepositoryBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getRuleKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(3, severity_); - } - for (int i = 0; i < param_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, param_.get(i)); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.ActiveRule prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code ActiveRule} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:ActiveRule) - org.sonar.batch.protocol.output.BatchReport.ActiveRuleOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.ActiveRule.class, org.sonar.batch.protocol.output.BatchReport.ActiveRule.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.ActiveRule.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getParamFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - ruleRepository_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - ruleKey_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - severity_ = 0; - bitField0_ = (bitField0_ & ~0x00000004); - if (paramBuilder_ == null) { - param_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - paramBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ActiveRule_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.ActiveRule.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule build() { - org.sonar.batch.protocol.output.BatchReport.ActiveRule result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule buildPartial() { - org.sonar.batch.protocol.output.BatchReport.ActiveRule result = new org.sonar.batch.protocol.output.BatchReport.ActiveRule(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.ruleRepository_ = ruleRepository_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.ruleKey_ = ruleKey_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.severity_ = severity_; - if (paramBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - param_ = java.util.Collections.unmodifiableList(param_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.param_ = param_; - } else { - result.param_ = paramBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.ActiveRule) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.ActiveRule)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.ActiveRule other) { - if (other == org.sonar.batch.protocol.output.BatchReport.ActiveRule.getDefaultInstance()) return this; - if (other.hasRuleRepository()) { - bitField0_ |= 0x00000001; - ruleRepository_ = other.ruleRepository_; - onChanged(); - } - if (other.hasRuleKey()) { - bitField0_ |= 0x00000002; - ruleKey_ = other.ruleKey_; - onChanged(); - } - if (other.hasSeverity()) { - setSeverity(other.getSeverity()); - } - if (paramBuilder_ == null) { - if (!other.param_.isEmpty()) { - if (param_.isEmpty()) { - param_ = other.param_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureParamIsMutable(); - param_.addAll(other.param_); - } - onChanged(); - } - } else { - if (!other.param_.isEmpty()) { - if (paramBuilder_.isEmpty()) { - paramBuilder_.dispose(); - paramBuilder_ = null; - param_ = other.param_; - bitField0_ = (bitField0_ & ~0x00000008); - paramBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getParamFieldBuilder() : null; - } else { - paramBuilder_.addAllMessages(other.param_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.ActiveRule parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.ActiveRule) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object ruleRepository_ = ""; - /** - * <code>optional string rule_repository = 1;</code> - */ - public boolean hasRuleRepository() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public java.lang.String getRuleRepository() { - java.lang.Object ref = ruleRepository_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleRepository_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public com.google.protobuf.ByteString - getRuleRepositoryBytes() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleRepository_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public Builder setRuleRepository( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - ruleRepository_ = value; - onChanged(); - return this; - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public Builder clearRuleRepository() { - bitField0_ = (bitField0_ & ~0x00000001); - ruleRepository_ = getDefaultInstance().getRuleRepository(); - onChanged(); - return this; - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public Builder setRuleRepositoryBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - ruleRepository_ = value; - onChanged(); - return this; - } - - private java.lang.Object ruleKey_ = ""; - /** - * <code>optional string rule_key = 2;</code> - */ - public boolean hasRuleKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string rule_key = 2;</code> - */ - public java.lang.String getRuleKey() { - java.lang.Object ref = ruleKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleKey_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string rule_key = 2;</code> - */ - public com.google.protobuf.ByteString - getRuleKeyBytes() { - java.lang.Object ref = ruleKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string rule_key = 2;</code> - */ - public Builder setRuleKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - ruleKey_ = value; - onChanged(); - return this; - } - /** - * <code>optional string rule_key = 2;</code> - */ - public Builder clearRuleKey() { - bitField0_ = (bitField0_ & ~0x00000002); - ruleKey_ = getDefaultInstance().getRuleKey(); - onChanged(); - return this; - } - /** - * <code>optional string rule_key = 2;</code> - */ - public Builder setRuleKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - ruleKey_ = value; - onChanged(); - return this; - } - - private int severity_ = 0; - /** - * <code>optional .Severity severity = 3;</code> - */ - public boolean hasSeverity() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional .Severity severity = 3;</code> - */ - public org.sonar.batch.protocol.Constants.Severity getSeverity() { - org.sonar.batch.protocol.Constants.Severity result = org.sonar.batch.protocol.Constants.Severity.valueOf(severity_); - return result == null ? org.sonar.batch.protocol.Constants.Severity.INFO : result; - } - /** - * <code>optional .Severity severity = 3;</code> - */ - public Builder setSeverity(org.sonar.batch.protocol.Constants.Severity value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - severity_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .Severity severity = 3;</code> - */ - public Builder clearSeverity() { - bitField0_ = (bitField0_ & ~0x00000004); - severity_ = 0; - onChanged(); - return this; - } - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam> param_ = - java.util.Collections.emptyList(); - private void ensureParamIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - param_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam>(param_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder> paramBuilder_; - - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam> getParamList() { - if (paramBuilder_ == null) { - return java.util.Collections.unmodifiableList(param_); - } else { - return paramBuilder_.getMessageList(); - } - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public int getParamCount() { - if (paramBuilder_ == null) { - return param_.size(); - } else { - return paramBuilder_.getCount(); - } - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam getParam(int index) { - if (paramBuilder_ == null) { - return param_.get(index); - } else { - return paramBuilder_.getMessage(index); - } - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder setParam( - int index, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam value) { - if (paramBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureParamIsMutable(); - param_.set(index, value); - onChanged(); - } else { - paramBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder setParam( - int index, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder builderForValue) { - if (paramBuilder_ == null) { - ensureParamIsMutable(); - param_.set(index, builderForValue.build()); - onChanged(); - } else { - paramBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder addParam(org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam value) { - if (paramBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureParamIsMutable(); - param_.add(value); - onChanged(); - } else { - paramBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder addParam( - int index, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam value) { - if (paramBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureParamIsMutable(); - param_.add(index, value); - onChanged(); - } else { - paramBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder addParam( - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder builderForValue) { - if (paramBuilder_ == null) { - ensureParamIsMutable(); - param_.add(builderForValue.build()); - onChanged(); - } else { - paramBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder addParam( - int index, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder builderForValue) { - if (paramBuilder_ == null) { - ensureParamIsMutable(); - param_.add(index, builderForValue.build()); - onChanged(); - } else { - paramBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder addAllParam( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam> values) { - if (paramBuilder_ == null) { - ensureParamIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, param_); - onChanged(); - } else { - paramBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder clearParam() { - if (paramBuilder_ == null) { - param_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - paramBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public Builder removeParam(int index) { - if (paramBuilder_ == null) { - ensureParamIsMutable(); - param_.remove(index); - onChanged(); - } else { - paramBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder getParamBuilder( - int index) { - return getParamFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder getParamOrBuilder( - int index) { - if (paramBuilder_ == null) { - return param_.get(index); } else { - return paramBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder> - getParamOrBuilderList() { - if (paramBuilder_ != null) { - return paramBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(param_); - } - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder addParamBuilder() { - return getParamFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.getDefaultInstance()); - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder addParamBuilder( - int index) { - return getParamFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.getDefaultInstance()); - } - /** - * <code>repeated .ActiveRule.ActiveRuleParam param = 4;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder> - getParamBuilderList() { - return getParamFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder> - getParamFieldBuilder() { - if (paramBuilder_ == null) { - paramBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParam.Builder, org.sonar.batch.protocol.output.BatchReport.ActiveRule.ActiveRuleParamOrBuilder>( - param_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - param_ = null; - } - return paramBuilder_; - } - - // @@protoc_insertion_point(builder_scope:ActiveRule) - } - - // @@protoc_insertion_point(class_scope:ActiveRule) - private static final org.sonar.batch.protocol.output.BatchReport.ActiveRule DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.ActiveRule(); - } - - public static org.sonar.batch.protocol.output.BatchReport.ActiveRule getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<ActiveRule> PARSER = - new com.google.protobuf.AbstractParser<ActiveRule>() { - public ActiveRule parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new ActiveRule(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<ActiveRule> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.ActiveRule getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ComponentLinkOrBuilder extends - // @@protoc_insertion_point(interface_extends:ComponentLink) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - boolean hasType(); - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - org.sonar.batch.protocol.Constants.ComponentLinkType getType(); - - /** - * <code>optional string href = 2;</code> - */ - boolean hasHref(); - /** - * <code>optional string href = 2;</code> - */ - java.lang.String getHref(); - /** - * <code>optional string href = 2;</code> - */ - com.google.protobuf.ByteString - getHrefBytes(); - } - /** - * Protobuf type {@code ComponentLink} - */ - public static final class ComponentLink extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:ComponentLink) - ComponentLinkOrBuilder { - // Use ComponentLink.newBuilder() to construct. - private ComponentLink(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private ComponentLink() { - type_ = 0; - href_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ComponentLink( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.ComponentLinkType value = org.sonar.batch.protocol.Constants.ComponentLinkType.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(1, rawValue); - } else { - bitField0_ |= 0x00000001; - type_ = rawValue; - } - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - href_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ComponentLink_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ComponentLink_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.ComponentLink.class, org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder.class); - } - - private int bitField0_; - public static final int TYPE_FIELD_NUMBER = 1; - private int type_; - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - public boolean hasType() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - public org.sonar.batch.protocol.Constants.ComponentLinkType getType() { - org.sonar.batch.protocol.Constants.ComponentLinkType result = org.sonar.batch.protocol.Constants.ComponentLinkType.valueOf(type_); - return result == null ? org.sonar.batch.protocol.Constants.ComponentLinkType.HOME : result; - } - - public static final int HREF_FIELD_NUMBER = 2; - private volatile java.lang.Object href_; - /** - * <code>optional string href = 2;</code> - */ - public boolean hasHref() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string href = 2;</code> - */ - public java.lang.String getHref() { - java.lang.Object ref = href_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - href_ = s; - } - return s; - } - } - /** - * <code>optional string href = 2;</code> - */ - public com.google.protobuf.ByteString - getHrefBytes() { - java.lang.Object ref = href_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - href_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeEnum(1, type_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getHrefBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(1, type_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getHrefBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.ComponentLink prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code ComponentLink} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:ComponentLink) - org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ComponentLink_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ComponentLink_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.ComponentLink.class, org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.ComponentLink.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - type_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - href_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_ComponentLink_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.ComponentLink getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.ComponentLink.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.ComponentLink build() { - org.sonar.batch.protocol.output.BatchReport.ComponentLink result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.ComponentLink buildPartial() { - org.sonar.batch.protocol.output.BatchReport.ComponentLink result = new org.sonar.batch.protocol.output.BatchReport.ComponentLink(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.type_ = type_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.href_ = href_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.ComponentLink) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.ComponentLink)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.ComponentLink other) { - if (other == org.sonar.batch.protocol.output.BatchReport.ComponentLink.getDefaultInstance()) return this; - if (other.hasType()) { - setType(other.getType()); - } - if (other.hasHref()) { - bitField0_ |= 0x00000002; - href_ = other.href_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.ComponentLink parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.ComponentLink) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int type_ = 0; - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - public boolean hasType() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - public org.sonar.batch.protocol.Constants.ComponentLinkType getType() { - org.sonar.batch.protocol.Constants.ComponentLinkType result = org.sonar.batch.protocol.Constants.ComponentLinkType.valueOf(type_); - return result == null ? org.sonar.batch.protocol.Constants.ComponentLinkType.HOME : result; - } - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - public Builder setType(org.sonar.batch.protocol.Constants.ComponentLinkType value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - type_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .ComponentLinkType type = 1;</code> - */ - public Builder clearType() { - bitField0_ = (bitField0_ & ~0x00000001); - type_ = 0; - onChanged(); - return this; - } - - private java.lang.Object href_ = ""; - /** - * <code>optional string href = 2;</code> - */ - public boolean hasHref() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string href = 2;</code> - */ - public java.lang.String getHref() { - java.lang.Object ref = href_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - href_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string href = 2;</code> - */ - public com.google.protobuf.ByteString - getHrefBytes() { - java.lang.Object ref = href_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - href_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string href = 2;</code> - */ - public Builder setHref( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - href_ = value; - onChanged(); - return this; - } - /** - * <code>optional string href = 2;</code> - */ - public Builder clearHref() { - bitField0_ = (bitField0_ & ~0x00000002); - href_ = getDefaultInstance().getHref(); - onChanged(); - return this; - } - /** - * <code>optional string href = 2;</code> - */ - public Builder setHrefBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - href_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:ComponentLink) - } - - // @@protoc_insertion_point(class_scope:ComponentLink) - private static final org.sonar.batch.protocol.output.BatchReport.ComponentLink DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.ComponentLink(); - } - - public static org.sonar.batch.protocol.output.BatchReport.ComponentLink getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<ComponentLink> PARSER = - new com.google.protobuf.AbstractParser<ComponentLink>() { - public ComponentLink parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new ComponentLink(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<ComponentLink> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.ComponentLink getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ComponentOrBuilder extends - // @@protoc_insertion_point(interface_extends:Component) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int32 ref = 1;</code> - */ - boolean hasRef(); - /** - * <code>optional int32 ref = 1;</code> - */ - int getRef(); - - /** - * <code>optional string path = 2;</code> - */ - boolean hasPath(); - /** - * <code>optional string path = 2;</code> - */ - java.lang.String getPath(); - /** - * <code>optional string path = 2;</code> - */ - com.google.protobuf.ByteString - getPathBytes(); - - /** - * <code>optional string name = 3;</code> - */ - boolean hasName(); - /** - * <code>optional string name = 3;</code> - */ - java.lang.String getName(); - /** - * <code>optional string name = 3;</code> - */ - com.google.protobuf.ByteString - getNameBytes(); - - /** - * <code>optional .ComponentType type = 4;</code> - */ - boolean hasType(); - /** - * <code>optional .ComponentType type = 4;</code> - */ - org.sonar.batch.protocol.Constants.ComponentType getType(); - - /** - * <code>optional bool is_test = 5;</code> - */ - boolean hasIsTest(); - /** - * <code>optional bool is_test = 5;</code> - */ - boolean getIsTest(); - - /** - * <code>optional string language = 6;</code> - */ - boolean hasLanguage(); - /** - * <code>optional string language = 6;</code> - */ - java.lang.String getLanguage(); - /** - * <code>optional string language = 6;</code> - */ - com.google.protobuf.ByteString - getLanguageBytes(); - - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - java.util.List<java.lang.Integer> getChildRefList(); - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - int getChildRefCount(); - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - int getChildRef(int index); - - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.ComponentLink> - getLinkList(); - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - org.sonar.batch.protocol.output.BatchReport.ComponentLink getLink(int index); - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - int getLinkCount(); - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder> - getLinkOrBuilderList(); - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder getLinkOrBuilder( - int index); - - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - boolean hasVersion(); - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - java.lang.String getVersion(); - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - com.google.protobuf.ByteString - getVersionBytes(); - - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - boolean hasKey(); - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - java.lang.String getKey(); - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - com.google.protobuf.ByteString - getKeyBytes(); - - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - boolean hasLines(); - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - int getLines(); - - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - boolean hasDescription(); - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - java.lang.String getDescription(); - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - com.google.protobuf.ByteString - getDescriptionBytes(); - } - /** - * Protobuf type {@code Component} - */ - public static final class Component extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Component) - ComponentOrBuilder { - // Use Component.newBuilder() to construct. - private Component(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Component() { - ref_ = 0; - path_ = ""; - name_ = ""; - type_ = 0; - isTest_ = false; - language_ = ""; - childRef_ = java.util.Collections.emptyList(); - link_ = java.util.Collections.emptyList(); - version_ = ""; - key_ = ""; - lines_ = 0; - description_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Component( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - ref_ = input.readInt32(); - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - path_ = bs; - break; - } - case 26: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000004; - name_ = bs; - break; - } - case 32: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.ComponentType value = org.sonar.batch.protocol.Constants.ComponentType.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(4, rawValue); - } else { - bitField0_ |= 0x00000008; - type_ = rawValue; - } - break; - } - case 40: { - bitField0_ |= 0x00000010; - isTest_ = input.readBool(); - break; - } - case 50: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000020; - language_ = bs; - break; - } - case 56: { - if (!((mutable_bitField0_ & 0x00000040) == 0x00000040)) { - childRef_ = new java.util.ArrayList<java.lang.Integer>(); - mutable_bitField0_ |= 0x00000040; - } - childRef_.add(input.readInt32()); - break; - } - case 58: { - int length = input.readRawVarint32(); - int limit = input.pushLimit(length); - if (!((mutable_bitField0_ & 0x00000040) == 0x00000040) && input.getBytesUntilLimit() > 0) { - childRef_ = new java.util.ArrayList<java.lang.Integer>(); - mutable_bitField0_ |= 0x00000040; - } - while (input.getBytesUntilLimit() > 0) { - childRef_.add(input.readInt32()); - } - input.popLimit(limit); - break; - } - case 66: { - if (!((mutable_bitField0_ & 0x00000080) == 0x00000080)) { - link_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.ComponentLink>(); - mutable_bitField0_ |= 0x00000080; - } - link_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.ComponentLink.PARSER, extensionRegistry)); - break; - } - case 74: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000040; - version_ = bs; - break; - } - case 82: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000080; - key_ = bs; - break; - } - case 88: { - bitField0_ |= 0x00000100; - lines_ = input.readInt32(); - break; - } - case 98: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000200; - description_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000040) == 0x00000040)) { - childRef_ = java.util.Collections.unmodifiableList(childRef_); - } - if (((mutable_bitField0_ & 0x00000080) == 0x00000080)) { - link_ = java.util.Collections.unmodifiableList(link_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Component_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Component_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Component.class, org.sonar.batch.protocol.output.BatchReport.Component.Builder.class); - } - - private int bitField0_; - public static final int REF_FIELD_NUMBER = 1; - private int ref_; - /** - * <code>optional int32 ref = 1;</code> - */ - public boolean hasRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 ref = 1;</code> - */ - public int getRef() { - return ref_; - } - - public static final int PATH_FIELD_NUMBER = 2; - private volatile java.lang.Object path_; - /** - * <code>optional string path = 2;</code> - */ - public boolean hasPath() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string path = 2;</code> - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - path_ = s; - } - return s; - } - } - /** - * <code>optional string path = 2;</code> - */ - public com.google.protobuf.ByteString - getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object name_; - /** - * <code>optional string name = 3;</code> - */ - public boolean hasName() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string name = 3;</code> - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - name_ = s; - } - return s; - } - } - /** - * <code>optional string name = 3;</code> - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TYPE_FIELD_NUMBER = 4; - private int type_; - /** - * <code>optional .ComponentType type = 4;</code> - */ - public boolean hasType() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional .ComponentType type = 4;</code> - */ - public org.sonar.batch.protocol.Constants.ComponentType getType() { - org.sonar.batch.protocol.Constants.ComponentType result = org.sonar.batch.protocol.Constants.ComponentType.valueOf(type_); - return result == null ? org.sonar.batch.protocol.Constants.ComponentType.PROJECT : result; - } - - public static final int IS_TEST_FIELD_NUMBER = 5; - private boolean isTest_; - /** - * <code>optional bool is_test = 5;</code> - */ - public boolean hasIsTest() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional bool is_test = 5;</code> - */ - public boolean getIsTest() { - return isTest_; - } - - public static final int LANGUAGE_FIELD_NUMBER = 6; - private volatile java.lang.Object language_; - /** - * <code>optional string language = 6;</code> - */ - public boolean hasLanguage() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional string language = 6;</code> - */ - public java.lang.String getLanguage() { - java.lang.Object ref = language_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - language_ = s; - } - return s; - } - } - /** - * <code>optional string language = 6;</code> - */ - public com.google.protobuf.ByteString - getLanguageBytes() { - java.lang.Object ref = language_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - language_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CHILD_REF_FIELD_NUMBER = 7; - private java.util.List<java.lang.Integer> childRef_; - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public java.util.List<java.lang.Integer> - getChildRefList() { - return childRef_; - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public int getChildRefCount() { - return childRef_.size(); - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public int getChildRef(int index) { - return childRef_.get(index); - } - private int childRefMemoizedSerializedSize = -1; - - public static final int LINK_FIELD_NUMBER = 8; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.ComponentLink> link_; - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.ComponentLink> getLinkList() { - return link_; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder> - getLinkOrBuilderList() { - return link_; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public int getLinkCount() { - return link_.size(); - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ComponentLink getLink(int index) { - return link_.get(index); - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder getLinkOrBuilder( - int index) { - return link_.get(index); - } - - public static final int VERSION_FIELD_NUMBER = 9; - private volatile java.lang.Object version_; - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public boolean hasVersion() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public java.lang.String getVersion() { - java.lang.Object ref = version_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - version_ = s; - } - return s; - } - } - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public com.google.protobuf.ByteString - getVersionBytes() { - java.lang.Object ref = version_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - version_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int KEY_FIELD_NUMBER = 10; - private volatile java.lang.Object key_; - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public boolean hasKey() { - return ((bitField0_ & 0x00000080) == 0x00000080); - } - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public java.lang.String getKey() { - java.lang.Object ref = key_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - key_ = s; - } - return s; - } - } - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public com.google.protobuf.ByteString - getKeyBytes() { - java.lang.Object ref = key_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - key_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LINES_FIELD_NUMBER = 11; - private int lines_; - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - public boolean hasLines() { - return ((bitField0_ & 0x00000100) == 0x00000100); - } - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - public int getLines() { - return lines_; - } - - public static final int DESCRIPTION_FIELD_NUMBER = 12; - private volatile java.lang.Object description_; - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public boolean hasDescription() { - return ((bitField0_ & 0x00000200) == 0x00000200); - } - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - description_ = s; - } - return s; - } - } - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public com.google.protobuf.ByteString - getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - getSerializedSize(); - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt32(1, ref_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getPathBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeBytes(3, getNameBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeEnum(4, type_); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - output.writeBool(5, isTest_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - output.writeBytes(6, getLanguageBytes()); - } - if (getChildRefList().size() > 0) { - output.writeRawVarint32(58); - output.writeRawVarint32(childRefMemoizedSerializedSize); - } - for (int i = 0; i < childRef_.size(); i++) { - output.writeInt32NoTag(childRef_.get(i)); - } - for (int i = 0; i < link_.size(); i++) { - output.writeMessage(8, link_.get(i)); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - output.writeBytes(9, getVersionBytes()); - } - if (((bitField0_ & 0x00000080) == 0x00000080)) { - output.writeBytes(10, getKeyBytes()); - } - if (((bitField0_ & 0x00000100) == 0x00000100)) { - output.writeInt32(11, lines_); - } - if (((bitField0_ & 0x00000200) == 0x00000200)) { - output.writeBytes(12, getDescriptionBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, ref_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getPathBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(3, getNameBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(4, type_); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(5, isTest_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(6, getLanguageBytes()); - } - { - int dataSize = 0; - for (int i = 0; i < childRef_.size(); i++) { - dataSize += com.google.protobuf.CodedOutputStream - .computeInt32SizeNoTag(childRef_.get(i)); - } - size += dataSize; - if (!getChildRefList().isEmpty()) { - size += 1; - size += com.google.protobuf.CodedOutputStream - .computeInt32SizeNoTag(dataSize); - } - childRefMemoizedSerializedSize = dataSize; - } - for (int i = 0; i < link_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(8, link_.get(i)); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(9, getVersionBytes()); - } - if (((bitField0_ & 0x00000080) == 0x00000080)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(10, getKeyBytes()); - } - if (((bitField0_ & 0x00000100) == 0x00000100)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(11, lines_); - } - if (((bitField0_ & 0x00000200) == 0x00000200)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(12, getDescriptionBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Component parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Component prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Component} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Component) - org.sonar.batch.protocol.output.BatchReport.ComponentOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Component_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Component_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Component.class, org.sonar.batch.protocol.output.BatchReport.Component.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Component.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getLinkFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - ref_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - path_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - name_ = ""; - bitField0_ = (bitField0_ & ~0x00000004); - type_ = 0; - bitField0_ = (bitField0_ & ~0x00000008); - isTest_ = false; - bitField0_ = (bitField0_ & ~0x00000010); - language_ = ""; - bitField0_ = (bitField0_ & ~0x00000020); - childRef_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); - if (linkBuilder_ == null) { - link_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000080); - } else { - linkBuilder_.clear(); - } - version_ = ""; - bitField0_ = (bitField0_ & ~0x00000100); - key_ = ""; - bitField0_ = (bitField0_ & ~0x00000200); - lines_ = 0; - bitField0_ = (bitField0_ & ~0x00000400); - description_ = ""; - bitField0_ = (bitField0_ & ~0x00000800); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Component_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Component getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Component.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Component build() { - org.sonar.batch.protocol.output.BatchReport.Component result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Component buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Component result = new org.sonar.batch.protocol.output.BatchReport.Component(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.ref_ = ref_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.path_ = path_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.name_ = name_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.type_ = type_; - if (((from_bitField0_ & 0x00000010) == 0x00000010)) { - to_bitField0_ |= 0x00000010; - } - result.isTest_ = isTest_; - if (((from_bitField0_ & 0x00000020) == 0x00000020)) { - to_bitField0_ |= 0x00000020; - } - result.language_ = language_; - if (((bitField0_ & 0x00000040) == 0x00000040)) { - childRef_ = java.util.Collections.unmodifiableList(childRef_); - bitField0_ = (bitField0_ & ~0x00000040); - } - result.childRef_ = childRef_; - if (linkBuilder_ == null) { - if (((bitField0_ & 0x00000080) == 0x00000080)) { - link_ = java.util.Collections.unmodifiableList(link_); - bitField0_ = (bitField0_ & ~0x00000080); - } - result.link_ = link_; - } else { - result.link_ = linkBuilder_.build(); - } - if (((from_bitField0_ & 0x00000100) == 0x00000100)) { - to_bitField0_ |= 0x00000040; - } - result.version_ = version_; - if (((from_bitField0_ & 0x00000200) == 0x00000200)) { - to_bitField0_ |= 0x00000080; - } - result.key_ = key_; - if (((from_bitField0_ & 0x00000400) == 0x00000400)) { - to_bitField0_ |= 0x00000100; - } - result.lines_ = lines_; - if (((from_bitField0_ & 0x00000800) == 0x00000800)) { - to_bitField0_ |= 0x00000200; - } - result.description_ = description_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Component) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Component)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Component other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Component.getDefaultInstance()) return this; - if (other.hasRef()) { - setRef(other.getRef()); - } - if (other.hasPath()) { - bitField0_ |= 0x00000002; - path_ = other.path_; - onChanged(); - } - if (other.hasName()) { - bitField0_ |= 0x00000004; - name_ = other.name_; - onChanged(); - } - if (other.hasType()) { - setType(other.getType()); - } - if (other.hasIsTest()) { - setIsTest(other.getIsTest()); - } - if (other.hasLanguage()) { - bitField0_ |= 0x00000020; - language_ = other.language_; - onChanged(); - } - if (!other.childRef_.isEmpty()) { - if (childRef_.isEmpty()) { - childRef_ = other.childRef_; - bitField0_ = (bitField0_ & ~0x00000040); - } else { - ensureChildRefIsMutable(); - childRef_.addAll(other.childRef_); - } - onChanged(); - } - if (linkBuilder_ == null) { - if (!other.link_.isEmpty()) { - if (link_.isEmpty()) { - link_ = other.link_; - bitField0_ = (bitField0_ & ~0x00000080); - } else { - ensureLinkIsMutable(); - link_.addAll(other.link_); - } - onChanged(); - } - } else { - if (!other.link_.isEmpty()) { - if (linkBuilder_.isEmpty()) { - linkBuilder_.dispose(); - linkBuilder_ = null; - link_ = other.link_; - bitField0_ = (bitField0_ & ~0x00000080); - linkBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getLinkFieldBuilder() : null; - } else { - linkBuilder_.addAllMessages(other.link_); - } - } - } - if (other.hasVersion()) { - bitField0_ |= 0x00000100; - version_ = other.version_; - onChanged(); - } - if (other.hasKey()) { - bitField0_ |= 0x00000200; - key_ = other.key_; - onChanged(); - } - if (other.hasLines()) { - setLines(other.getLines()); - } - if (other.hasDescription()) { - bitField0_ |= 0x00000800; - description_ = other.description_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Component parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Component) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int ref_ ; - /** - * <code>optional int32 ref = 1;</code> - */ - public boolean hasRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 ref = 1;</code> - */ - public int getRef() { - return ref_; - } - /** - * <code>optional int32 ref = 1;</code> - */ - public Builder setRef(int value) { - bitField0_ |= 0x00000001; - ref_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 ref = 1;</code> - */ - public Builder clearRef() { - bitField0_ = (bitField0_ & ~0x00000001); - ref_ = 0; - onChanged(); - return this; - } - - private java.lang.Object path_ = ""; - /** - * <code>optional string path = 2;</code> - */ - public boolean hasPath() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string path = 2;</code> - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - path_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string path = 2;</code> - */ - public com.google.protobuf.ByteString - getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string path = 2;</code> - */ - public Builder setPath( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - path_ = value; - onChanged(); - return this; - } - /** - * <code>optional string path = 2;</code> - */ - public Builder clearPath() { - bitField0_ = (bitField0_ & ~0x00000002); - path_ = getDefaultInstance().getPath(); - onChanged(); - return this; - } - /** - * <code>optional string path = 2;</code> - */ - public Builder setPathBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - path_ = value; - onChanged(); - return this; - } - - private java.lang.Object name_ = ""; - /** - * <code>optional string name = 3;</code> - */ - public boolean hasName() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string name = 3;</code> - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - name_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string name = 3;</code> - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string name = 3;</code> - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - name_ = value; - onChanged(); - return this; - } - /** - * <code>optional string name = 3;</code> - */ - public Builder clearName() { - bitField0_ = (bitField0_ & ~0x00000004); - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * <code>optional string name = 3;</code> - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - name_ = value; - onChanged(); - return this; - } - - private int type_ = 0; - /** - * <code>optional .ComponentType type = 4;</code> - */ - public boolean hasType() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional .ComponentType type = 4;</code> - */ - public org.sonar.batch.protocol.Constants.ComponentType getType() { - org.sonar.batch.protocol.Constants.ComponentType result = org.sonar.batch.protocol.Constants.ComponentType.valueOf(type_); - return result == null ? org.sonar.batch.protocol.Constants.ComponentType.PROJECT : result; - } - /** - * <code>optional .ComponentType type = 4;</code> - */ - public Builder setType(org.sonar.batch.protocol.Constants.ComponentType value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - type_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .ComponentType type = 4;</code> - */ - public Builder clearType() { - bitField0_ = (bitField0_ & ~0x00000008); - type_ = 0; - onChanged(); - return this; - } - - private boolean isTest_ ; - /** - * <code>optional bool is_test = 5;</code> - */ - public boolean hasIsTest() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional bool is_test = 5;</code> - */ - public boolean getIsTest() { - return isTest_; - } - /** - * <code>optional bool is_test = 5;</code> - */ - public Builder setIsTest(boolean value) { - bitField0_ |= 0x00000010; - isTest_ = value; - onChanged(); - return this; - } - /** - * <code>optional bool is_test = 5;</code> - */ - public Builder clearIsTest() { - bitField0_ = (bitField0_ & ~0x00000010); - isTest_ = false; - onChanged(); - return this; - } - - private java.lang.Object language_ = ""; - /** - * <code>optional string language = 6;</code> - */ - public boolean hasLanguage() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional string language = 6;</code> - */ - public java.lang.String getLanguage() { - java.lang.Object ref = language_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - language_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string language = 6;</code> - */ - public com.google.protobuf.ByteString - getLanguageBytes() { - java.lang.Object ref = language_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - language_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string language = 6;</code> - */ - public Builder setLanguage( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000020; - language_ = value; - onChanged(); - return this; - } - /** - * <code>optional string language = 6;</code> - */ - public Builder clearLanguage() { - bitField0_ = (bitField0_ & ~0x00000020); - language_ = getDefaultInstance().getLanguage(); - onChanged(); - return this; - } - /** - * <code>optional string language = 6;</code> - */ - public Builder setLanguageBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000020; - language_ = value; - onChanged(); - return this; - } - - private java.util.List<java.lang.Integer> childRef_ = java.util.Collections.emptyList(); - private void ensureChildRefIsMutable() { - if (!((bitField0_ & 0x00000040) == 0x00000040)) { - childRef_ = new java.util.ArrayList<java.lang.Integer>(childRef_); - bitField0_ |= 0x00000040; - } - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public java.util.List<java.lang.Integer> - getChildRefList() { - return java.util.Collections.unmodifiableList(childRef_); - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public int getChildRefCount() { - return childRef_.size(); - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public int getChildRef(int index) { - return childRef_.get(index); - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public Builder setChildRef( - int index, int value) { - ensureChildRefIsMutable(); - childRef_.set(index, value); - onChanged(); - return this; - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public Builder addChildRef(int value) { - ensureChildRefIsMutable(); - childRef_.add(value); - onChanged(); - return this; - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public Builder addAllChildRef( - java.lang.Iterable<? extends java.lang.Integer> values) { - ensureChildRefIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, childRef_); - onChanged(); - return this; - } - /** - * <code>repeated int32 child_ref = 7 [packed = true];</code> - */ - public Builder clearChildRef() { - childRef_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); - onChanged(); - return this; - } - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.ComponentLink> link_ = - java.util.Collections.emptyList(); - private void ensureLinkIsMutable() { - if (!((bitField0_ & 0x00000080) == 0x00000080)) { - link_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.ComponentLink>(link_); - bitField0_ |= 0x00000080; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.ComponentLink, org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder, org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder> linkBuilder_; - - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.ComponentLink> getLinkList() { - if (linkBuilder_ == null) { - return java.util.Collections.unmodifiableList(link_); - } else { - return linkBuilder_.getMessageList(); - } - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public int getLinkCount() { - if (linkBuilder_ == null) { - return link_.size(); - } else { - return linkBuilder_.getCount(); - } - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ComponentLink getLink(int index) { - if (linkBuilder_ == null) { - return link_.get(index); - } else { - return linkBuilder_.getMessage(index); - } - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder setLink( - int index, org.sonar.batch.protocol.output.BatchReport.ComponentLink value) { - if (linkBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLinkIsMutable(); - link_.set(index, value); - onChanged(); - } else { - linkBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder setLink( - int index, org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder builderForValue) { - if (linkBuilder_ == null) { - ensureLinkIsMutable(); - link_.set(index, builderForValue.build()); - onChanged(); - } else { - linkBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder addLink(org.sonar.batch.protocol.output.BatchReport.ComponentLink value) { - if (linkBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLinkIsMutable(); - link_.add(value); - onChanged(); - } else { - linkBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder addLink( - int index, org.sonar.batch.protocol.output.BatchReport.ComponentLink value) { - if (linkBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLinkIsMutable(); - link_.add(index, value); - onChanged(); - } else { - linkBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder addLink( - org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder builderForValue) { - if (linkBuilder_ == null) { - ensureLinkIsMutable(); - link_.add(builderForValue.build()); - onChanged(); - } else { - linkBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder addLink( - int index, org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder builderForValue) { - if (linkBuilder_ == null) { - ensureLinkIsMutable(); - link_.add(index, builderForValue.build()); - onChanged(); - } else { - linkBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder addAllLink( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.ComponentLink> values) { - if (linkBuilder_ == null) { - ensureLinkIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, link_); - onChanged(); - } else { - linkBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder clearLink() { - if (linkBuilder_ == null) { - link_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000080); - onChanged(); - } else { - linkBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public Builder removeLink(int index) { - if (linkBuilder_ == null) { - ensureLinkIsMutable(); - link_.remove(index); - onChanged(); - } else { - linkBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder getLinkBuilder( - int index) { - return getLinkFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder getLinkOrBuilder( - int index) { - if (linkBuilder_ == null) { - return link_.get(index); } else { - return linkBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder> - getLinkOrBuilderList() { - if (linkBuilder_ != null) { - return linkBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(link_); - } - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder addLinkBuilder() { - return getLinkFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.ComponentLink.getDefaultInstance()); - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder addLinkBuilder( - int index) { - return getLinkFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.ComponentLink.getDefaultInstance()); - } - /** - * <code>repeated .ComponentLink link = 8;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder> - getLinkBuilderList() { - return getLinkFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.ComponentLink, org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder, org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder> - getLinkFieldBuilder() { - if (linkBuilder_ == null) { - linkBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.ComponentLink, org.sonar.batch.protocol.output.BatchReport.ComponentLink.Builder, org.sonar.batch.protocol.output.BatchReport.ComponentLinkOrBuilder>( - link_, - ((bitField0_ & 0x00000080) == 0x00000080), - getParentForChildren(), - isClean()); - link_ = null; - } - return linkBuilder_; - } - - private java.lang.Object version_ = ""; - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public boolean hasVersion() { - return ((bitField0_ & 0x00000100) == 0x00000100); - } - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public java.lang.String getVersion() { - java.lang.Object ref = version_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - version_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public com.google.protobuf.ByteString - getVersionBytes() { - java.lang.Object ref = version_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - version_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public Builder setVersion( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000100; - version_ = value; - onChanged(); - return this; - } - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public Builder clearVersion() { - bitField0_ = (bitField0_ & ~0x00000100); - version_ = getDefaultInstance().getVersion(); - onChanged(); - return this; - } - /** - * <code>optional string version = 9;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public Builder setVersionBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000100; - version_ = value; - onChanged(); - return this; - } - - private java.lang.Object key_ = ""; - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public boolean hasKey() { - return ((bitField0_ & 0x00000200) == 0x00000200); - } - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public java.lang.String getKey() { - java.lang.Object ref = key_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - key_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public com.google.protobuf.ByteString - getKeyBytes() { - java.lang.Object ref = key_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - key_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public Builder setKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000200; - key_ = value; - onChanged(); - return this; - } - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public Builder clearKey() { - bitField0_ = (bitField0_ & ~0x00000200); - key_ = getDefaultInstance().getKey(); - onChanged(); - return this; - } - /** - * <code>optional string key = 10;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * TODO rename this property -> batchKey ? moduleKey ? - * </pre> - */ - public Builder setKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000200; - key_ = value; - onChanged(); - return this; - } - - private int lines_ ; - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - public boolean hasLines() { - return ((bitField0_ & 0x00000400) == 0x00000400); - } - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - public int getLines() { - return lines_; - } - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - public Builder setLines(int value) { - bitField0_ |= 0x00000400; - lines_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 lines = 11;</code> - * - * <pre> - * Only available on FILE type - * </pre> - */ - public Builder clearLines() { - bitField0_ = (bitField0_ & ~0x00000400); - lines_ = 0; - onChanged(); - return this; - } - - private java.lang.Object description_ = ""; - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public boolean hasDescription() { - return ((bitField0_ & 0x00000800) == 0x00000800); - } - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - description_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public com.google.protobuf.ByteString - getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public Builder setDescription( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000800; - description_ = value; - onChanged(); - return this; - } - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public Builder clearDescription() { - bitField0_ = (bitField0_ & ~0x00000800); - description_ = getDefaultInstance().getDescription(); - onChanged(); - return this; - } - /** - * <code>optional string description = 12;</code> - * - * <pre> - * Only available on PROJECT and MODULE types - * </pre> - */ - public Builder setDescriptionBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000800; - description_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Component) - } - - // @@protoc_insertion_point(class_scope:Component) - private static final org.sonar.batch.protocol.output.BatchReport.Component DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Component(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Component getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Component> PARSER = - new com.google.protobuf.AbstractParser<Component>() { - public Component parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Component(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Component> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Component getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface MeasureOrBuilder extends - // @@protoc_insertion_point(interface_extends:Measure) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - boolean hasValueType(); - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - org.sonar.batch.protocol.Constants.MeasureValueType getValueType(); - - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - boolean hasBooleanValue(); - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - boolean getBooleanValue(); - - /** - * <code>optional int32 int_value = 3;</code> - */ - boolean hasIntValue(); - /** - * <code>optional int32 int_value = 3;</code> - */ - int getIntValue(); - - /** - * <code>optional int64 long_value = 4;</code> - */ - boolean hasLongValue(); - /** - * <code>optional int64 long_value = 4;</code> - */ - long getLongValue(); - - /** - * <code>optional double double_value = 5;</code> - */ - boolean hasDoubleValue(); - /** - * <code>optional double double_value = 5;</code> - */ - double getDoubleValue(); - - /** - * <code>optional string string_value = 6;</code> - */ - boolean hasStringValue(); - /** - * <code>optional string string_value = 6;</code> - */ - java.lang.String getStringValue(); - /** - * <code>optional string string_value = 6;</code> - */ - com.google.protobuf.ByteString - getStringValueBytes(); - - /** - * <code>optional string metric_key = 7;</code> - */ - boolean hasMetricKey(); - /** - * <code>optional string metric_key = 7;</code> - */ - java.lang.String getMetricKey(); - /** - * <code>optional string metric_key = 7;</code> - */ - com.google.protobuf.ByteString - getMetricKeyBytes(); - } - /** - * Protobuf type {@code Measure} - */ - public static final class Measure extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Measure) - MeasureOrBuilder { - // Use Measure.newBuilder() to construct. - private Measure(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Measure() { - valueType_ = 0; - booleanValue_ = false; - intValue_ = 0; - longValue_ = 0L; - doubleValue_ = 0D; - stringValue_ = ""; - metricKey_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Measure( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.MeasureValueType value = org.sonar.batch.protocol.Constants.MeasureValueType.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(1, rawValue); - } else { - bitField0_ |= 0x00000001; - valueType_ = rawValue; - } - break; - } - case 16: { - bitField0_ |= 0x00000002; - booleanValue_ = input.readBool(); - break; - } - case 24: { - bitField0_ |= 0x00000004; - intValue_ = input.readInt32(); - break; - } - case 32: { - bitField0_ |= 0x00000008; - longValue_ = input.readInt64(); - break; - } - case 41: { - bitField0_ |= 0x00000010; - doubleValue_ = input.readDouble(); - break; - } - case 50: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000020; - stringValue_ = bs; - break; - } - case 58: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000040; - metricKey_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Measure_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Measure_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Measure.class, org.sonar.batch.protocol.output.BatchReport.Measure.Builder.class); - } - - private int bitField0_; - public static final int VALUE_TYPE_FIELD_NUMBER = 1; - private int valueType_; - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - public boolean hasValueType() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - public org.sonar.batch.protocol.Constants.MeasureValueType getValueType() { - org.sonar.batch.protocol.Constants.MeasureValueType result = org.sonar.batch.protocol.Constants.MeasureValueType.valueOf(valueType_); - return result == null ? org.sonar.batch.protocol.Constants.MeasureValueType.INT : result; - } - - public static final int BOOLEAN_VALUE_FIELD_NUMBER = 2; - private boolean booleanValue_; - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - public boolean hasBooleanValue() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - public boolean getBooleanValue() { - return booleanValue_; - } - - public static final int INT_VALUE_FIELD_NUMBER = 3; - private int intValue_; - /** - * <code>optional int32 int_value = 3;</code> - */ - public boolean hasIntValue() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int32 int_value = 3;</code> - */ - public int getIntValue() { - return intValue_; - } - - public static final int LONG_VALUE_FIELD_NUMBER = 4; - private long longValue_; - /** - * <code>optional int64 long_value = 4;</code> - */ - public boolean hasLongValue() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional int64 long_value = 4;</code> - */ - public long getLongValue() { - return longValue_; - } - - public static final int DOUBLE_VALUE_FIELD_NUMBER = 5; - private double doubleValue_; - /** - * <code>optional double double_value = 5;</code> - */ - public boolean hasDoubleValue() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional double double_value = 5;</code> - */ - public double getDoubleValue() { - return doubleValue_; - } - - public static final int STRING_VALUE_FIELD_NUMBER = 6; - private volatile java.lang.Object stringValue_; - /** - * <code>optional string string_value = 6;</code> - */ - public boolean hasStringValue() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional string string_value = 6;</code> - */ - public java.lang.String getStringValue() { - java.lang.Object ref = stringValue_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - stringValue_ = s; - } - return s; - } - } - /** - * <code>optional string string_value = 6;</code> - */ - public com.google.protobuf.ByteString - getStringValueBytes() { - java.lang.Object ref = stringValue_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - stringValue_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int METRIC_KEY_FIELD_NUMBER = 7; - private volatile java.lang.Object metricKey_; - /** - * <code>optional string metric_key = 7;</code> - */ - public boolean hasMetricKey() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional string metric_key = 7;</code> - */ - public java.lang.String getMetricKey() { - java.lang.Object ref = metricKey_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - metricKey_ = s; - } - return s; - } - } - /** - * <code>optional string metric_key = 7;</code> - */ - public com.google.protobuf.ByteString - getMetricKeyBytes() { - java.lang.Object ref = metricKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - metricKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeEnum(1, valueType_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBool(2, booleanValue_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeInt32(3, intValue_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeInt64(4, longValue_); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - output.writeDouble(5, doubleValue_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - output.writeBytes(6, getStringValueBytes()); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - output.writeBytes(7, getMetricKeyBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(1, valueType_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(2, booleanValue_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(3, intValue_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(4, longValue_); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - size += com.google.protobuf.CodedOutputStream - .computeDoubleSize(5, doubleValue_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(6, getStringValueBytes()); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(7, getMetricKeyBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Measure parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Measure prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Measure} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Measure) - org.sonar.batch.protocol.output.BatchReport.MeasureOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Measure_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Measure_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Measure.class, org.sonar.batch.protocol.output.BatchReport.Measure.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Measure.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - valueType_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - booleanValue_ = false; - bitField0_ = (bitField0_ & ~0x00000002); - intValue_ = 0; - bitField0_ = (bitField0_ & ~0x00000004); - longValue_ = 0L; - bitField0_ = (bitField0_ & ~0x00000008); - doubleValue_ = 0D; - bitField0_ = (bitField0_ & ~0x00000010); - stringValue_ = ""; - bitField0_ = (bitField0_ & ~0x00000020); - metricKey_ = ""; - bitField0_ = (bitField0_ & ~0x00000040); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Measure_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Measure getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Measure.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Measure build() { - org.sonar.batch.protocol.output.BatchReport.Measure result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Measure buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Measure result = new org.sonar.batch.protocol.output.BatchReport.Measure(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.valueType_ = valueType_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.booleanValue_ = booleanValue_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.intValue_ = intValue_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.longValue_ = longValue_; - if (((from_bitField0_ & 0x00000010) == 0x00000010)) { - to_bitField0_ |= 0x00000010; - } - result.doubleValue_ = doubleValue_; - if (((from_bitField0_ & 0x00000020) == 0x00000020)) { - to_bitField0_ |= 0x00000020; - } - result.stringValue_ = stringValue_; - if (((from_bitField0_ & 0x00000040) == 0x00000040)) { - to_bitField0_ |= 0x00000040; - } - result.metricKey_ = metricKey_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Measure) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Measure)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Measure other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Measure.getDefaultInstance()) return this; - if (other.hasValueType()) { - setValueType(other.getValueType()); - } - if (other.hasBooleanValue()) { - setBooleanValue(other.getBooleanValue()); - } - if (other.hasIntValue()) { - setIntValue(other.getIntValue()); - } - if (other.hasLongValue()) { - setLongValue(other.getLongValue()); - } - if (other.hasDoubleValue()) { - setDoubleValue(other.getDoubleValue()); - } - if (other.hasStringValue()) { - bitField0_ |= 0x00000020; - stringValue_ = other.stringValue_; - onChanged(); - } - if (other.hasMetricKey()) { - bitField0_ |= 0x00000040; - metricKey_ = other.metricKey_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Measure parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Measure) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int valueType_ = 0; - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - public boolean hasValueType() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - public org.sonar.batch.protocol.Constants.MeasureValueType getValueType() { - org.sonar.batch.protocol.Constants.MeasureValueType result = org.sonar.batch.protocol.Constants.MeasureValueType.valueOf(valueType_); - return result == null ? org.sonar.batch.protocol.Constants.MeasureValueType.INT : result; - } - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - public Builder setValueType(org.sonar.batch.protocol.Constants.MeasureValueType value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - valueType_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .MeasureValueType value_type = 1;</code> - */ - public Builder clearValueType() { - bitField0_ = (bitField0_ & ~0x00000001); - valueType_ = 0; - onChanged(); - return this; - } - - private boolean booleanValue_ ; - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - public boolean hasBooleanValue() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - public boolean getBooleanValue() { - return booleanValue_; - } - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - public Builder setBooleanValue(boolean value) { - bitField0_ |= 0x00000002; - booleanValue_ = value; - onChanged(); - return this; - } - /** - * <code>optional bool boolean_value = 2;</code> - * - * <pre> - * all values may be unset for "new_xxx" measures (only variations are populated) - * </pre> - */ - public Builder clearBooleanValue() { - bitField0_ = (bitField0_ & ~0x00000002); - booleanValue_ = false; - onChanged(); - return this; - } - - private int intValue_ ; - /** - * <code>optional int32 int_value = 3;</code> - */ - public boolean hasIntValue() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int32 int_value = 3;</code> - */ - public int getIntValue() { - return intValue_; - } - /** - * <code>optional int32 int_value = 3;</code> - */ - public Builder setIntValue(int value) { - bitField0_ |= 0x00000004; - intValue_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 int_value = 3;</code> - */ - public Builder clearIntValue() { - bitField0_ = (bitField0_ & ~0x00000004); - intValue_ = 0; - onChanged(); - return this; - } - - private long longValue_ ; - /** - * <code>optional int64 long_value = 4;</code> - */ - public boolean hasLongValue() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional int64 long_value = 4;</code> - */ - public long getLongValue() { - return longValue_; - } - /** - * <code>optional int64 long_value = 4;</code> - */ - public Builder setLongValue(long value) { - bitField0_ |= 0x00000008; - longValue_ = value; - onChanged(); - return this; - } - /** - * <code>optional int64 long_value = 4;</code> - */ - public Builder clearLongValue() { - bitField0_ = (bitField0_ & ~0x00000008); - longValue_ = 0L; - onChanged(); - return this; - } - - private double doubleValue_ ; - /** - * <code>optional double double_value = 5;</code> - */ - public boolean hasDoubleValue() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional double double_value = 5;</code> - */ - public double getDoubleValue() { - return doubleValue_; - } - /** - * <code>optional double double_value = 5;</code> - */ - public Builder setDoubleValue(double value) { - bitField0_ |= 0x00000010; - doubleValue_ = value; - onChanged(); - return this; - } - /** - * <code>optional double double_value = 5;</code> - */ - public Builder clearDoubleValue() { - bitField0_ = (bitField0_ & ~0x00000010); - doubleValue_ = 0D; - onChanged(); - return this; - } - - private java.lang.Object stringValue_ = ""; - /** - * <code>optional string string_value = 6;</code> - */ - public boolean hasStringValue() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional string string_value = 6;</code> - */ - public java.lang.String getStringValue() { - java.lang.Object ref = stringValue_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - stringValue_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string string_value = 6;</code> - */ - public com.google.protobuf.ByteString - getStringValueBytes() { - java.lang.Object ref = stringValue_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - stringValue_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string string_value = 6;</code> - */ - public Builder setStringValue( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000020; - stringValue_ = value; - onChanged(); - return this; - } - /** - * <code>optional string string_value = 6;</code> - */ - public Builder clearStringValue() { - bitField0_ = (bitField0_ & ~0x00000020); - stringValue_ = getDefaultInstance().getStringValue(); - onChanged(); - return this; - } - /** - * <code>optional string string_value = 6;</code> - */ - public Builder setStringValueBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000020; - stringValue_ = value; - onChanged(); - return this; - } - - private java.lang.Object metricKey_ = ""; - /** - * <code>optional string metric_key = 7;</code> - */ - public boolean hasMetricKey() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional string metric_key = 7;</code> - */ - public java.lang.String getMetricKey() { - java.lang.Object ref = metricKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - metricKey_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string metric_key = 7;</code> - */ - public com.google.protobuf.ByteString - getMetricKeyBytes() { - java.lang.Object ref = metricKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - metricKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string metric_key = 7;</code> - */ - public Builder setMetricKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000040; - metricKey_ = value; - onChanged(); - return this; - } - /** - * <code>optional string metric_key = 7;</code> - */ - public Builder clearMetricKey() { - bitField0_ = (bitField0_ & ~0x00000040); - metricKey_ = getDefaultInstance().getMetricKey(); - onChanged(); - return this; - } - /** - * <code>optional string metric_key = 7;</code> - */ - public Builder setMetricKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000040; - metricKey_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Measure) - } - - // @@protoc_insertion_point(class_scope:Measure) - private static final org.sonar.batch.protocol.output.BatchReport.Measure DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Measure(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Measure getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Measure> PARSER = - new com.google.protobuf.AbstractParser<Measure>() { - public Measure parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Measure(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Measure> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Measure getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface IssueOrBuilder extends - // @@protoc_insertion_point(interface_extends:Issue) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string rule_repository = 1;</code> - */ - boolean hasRuleRepository(); - /** - * <code>optional string rule_repository = 1;</code> - */ - java.lang.String getRuleRepository(); - /** - * <code>optional string rule_repository = 1;</code> - */ - com.google.protobuf.ByteString - getRuleRepositoryBytes(); - - /** - * <code>optional string rule_key = 2;</code> - */ - boolean hasRuleKey(); - /** - * <code>optional string rule_key = 2;</code> - */ - java.lang.String getRuleKey(); - /** - * <code>optional string rule_key = 2;</code> - */ - com.google.protobuf.ByteString - getRuleKeyBytes(); - - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - boolean hasLine(); - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - int getLine(); - - /** - * <code>optional string msg = 4;</code> - */ - boolean hasMsg(); - /** - * <code>optional string msg = 4;</code> - */ - java.lang.String getMsg(); - /** - * <code>optional string msg = 4;</code> - */ - com.google.protobuf.ByteString - getMsgBytes(); - - /** - * <code>optional .Severity severity = 5;</code> - */ - boolean hasSeverity(); - /** - * <code>optional .Severity severity = 5;</code> - */ - org.sonar.batch.protocol.Constants.Severity getSeverity(); - - /** - * <code>optional double effort_to_fix = 6;</code> - */ - boolean hasEffortToFix(); - /** - * <code>optional double effort_to_fix = 6;</code> - */ - double getEffortToFix(); - - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - boolean hasTextRange(); - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - org.sonar.batch.protocol.output.BatchReport.TextRange getTextRange(); - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getTextRangeOrBuilder(); - - /** - * <code>repeated .Flow flow = 8;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.Flow> - getFlowList(); - /** - * <code>repeated .Flow flow = 8;</code> - */ - org.sonar.batch.protocol.output.BatchReport.Flow getFlow(int index); - /** - * <code>repeated .Flow flow = 8;</code> - */ - int getFlowCount(); - /** - * <code>repeated .Flow flow = 8;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder> - getFlowOrBuilderList(); - /** - * <code>repeated .Flow flow = 8;</code> - */ - org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder getFlowOrBuilder( - int index); - } - /** - * Protobuf type {@code Issue} - */ - public static final class Issue extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Issue) - IssueOrBuilder { - // Use Issue.newBuilder() to construct. - private Issue(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Issue() { - ruleRepository_ = ""; - ruleKey_ = ""; - line_ = 0; - msg_ = ""; - severity_ = 0; - effortToFix_ = 0D; - flow_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Issue( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - ruleRepository_ = bs; - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - ruleKey_ = bs; - break; - } - case 24: { - bitField0_ |= 0x00000004; - line_ = input.readInt32(); - break; - } - case 34: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000008; - msg_ = bs; - break; - } - case 40: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.Severity value = org.sonar.batch.protocol.Constants.Severity.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(5, rawValue); - } else { - bitField0_ |= 0x00000010; - severity_ = rawValue; - } - break; - } - case 49: { - bitField0_ |= 0x00000020; - effortToFix_ = input.readDouble(); - break; - } - case 58: { - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder subBuilder = null; - if (((bitField0_ & 0x00000040) == 0x00000040)) { - subBuilder = textRange_.toBuilder(); - } - textRange_ = input.readMessage(org.sonar.batch.protocol.output.BatchReport.TextRange.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(textRange_); - textRange_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000040; - break; - } - case 66: { - if (!((mutable_bitField0_ & 0x00000080) == 0x00000080)) { - flow_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.Flow>(); - mutable_bitField0_ |= 0x00000080; - } - flow_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.Flow.PARSER, extensionRegistry)); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000080) == 0x00000080)) { - flow_ = java.util.Collections.unmodifiableList(flow_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Issue_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Issue_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Issue.class, org.sonar.batch.protocol.output.BatchReport.Issue.Builder.class); - } - - private int bitField0_; - public static final int RULE_REPOSITORY_FIELD_NUMBER = 1; - private volatile java.lang.Object ruleRepository_; - /** - * <code>optional string rule_repository = 1;</code> - */ - public boolean hasRuleRepository() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public java.lang.String getRuleRepository() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleRepository_ = s; - } - return s; - } - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public com.google.protobuf.ByteString - getRuleRepositoryBytes() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleRepository_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int RULE_KEY_FIELD_NUMBER = 2; - private volatile java.lang.Object ruleKey_; - /** - * <code>optional string rule_key = 2;</code> - */ - public boolean hasRuleKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string rule_key = 2;</code> - */ - public java.lang.String getRuleKey() { - java.lang.Object ref = ruleKey_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleKey_ = s; - } - return s; - } - } - /** - * <code>optional string rule_key = 2;</code> - */ - public com.google.protobuf.ByteString - getRuleKeyBytes() { - java.lang.Object ref = ruleKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LINE_FIELD_NUMBER = 3; - private int line_; - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - public boolean hasLine() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - public int getLine() { - return line_; - } - - public static final int MSG_FIELD_NUMBER = 4; - private volatile java.lang.Object msg_; - /** - * <code>optional string msg = 4;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional string msg = 4;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } - } - /** - * <code>optional string msg = 4;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SEVERITY_FIELD_NUMBER = 5; - private int severity_; - /** - * <code>optional .Severity severity = 5;</code> - */ - public boolean hasSeverity() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional .Severity severity = 5;</code> - */ - public org.sonar.batch.protocol.Constants.Severity getSeverity() { - org.sonar.batch.protocol.Constants.Severity result = org.sonar.batch.protocol.Constants.Severity.valueOf(severity_); - return result == null ? org.sonar.batch.protocol.Constants.Severity.INFO : result; - } - - public static final int EFFORT_TO_FIX_FIELD_NUMBER = 6; - private double effortToFix_; - /** - * <code>optional double effort_to_fix = 6;</code> - */ - public boolean hasEffortToFix() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional double effort_to_fix = 6;</code> - */ - public double getEffortToFix() { - return effortToFix_; - } - - public static final int TEXT_RANGE_FIELD_NUMBER = 7; - private org.sonar.batch.protocol.output.BatchReport.TextRange textRange_; - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public boolean hasTextRange() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getTextRange() { - return textRange_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getTextRangeOrBuilder() { - return textRange_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } - - public static final int FLOW_FIELD_NUMBER = 8; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.Flow> flow_; - /** - * <code>repeated .Flow flow = 8;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Flow> getFlowList() { - return flow_; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder> - getFlowOrBuilderList() { - return flow_; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public int getFlowCount() { - return flow_.size(); - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Flow getFlow(int index) { - return flow_.get(index); - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder getFlowOrBuilder( - int index) { - return flow_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getRuleRepositoryBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getRuleKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeInt32(3, line_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeBytes(4, getMsgBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - output.writeEnum(5, severity_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - output.writeDouble(6, effortToFix_); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - output.writeMessage(7, getTextRange()); - } - for (int i = 0; i < flow_.size(); i++) { - output.writeMessage(8, flow_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getRuleRepositoryBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getRuleKeyBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(3, line_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(4, getMsgBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(5, severity_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - size += com.google.protobuf.CodedOutputStream - .computeDoubleSize(6, effortToFix_); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(7, getTextRange()); - } - for (int i = 0; i < flow_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(8, flow_.get(i)); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Issue parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Issue prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Issue} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Issue) - org.sonar.batch.protocol.output.BatchReport.IssueOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Issue_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Issue_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Issue.class, org.sonar.batch.protocol.output.BatchReport.Issue.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Issue.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getTextRangeFieldBuilder(); - getFlowFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - ruleRepository_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - ruleKey_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - line_ = 0; - bitField0_ = (bitField0_ & ~0x00000004); - msg_ = ""; - bitField0_ = (bitField0_ & ~0x00000008); - severity_ = 0; - bitField0_ = (bitField0_ & ~0x00000010); - effortToFix_ = 0D; - bitField0_ = (bitField0_ & ~0x00000020); - if (textRangeBuilder_ == null) { - textRange_ = null; - } else { - textRangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000040); - if (flowBuilder_ == null) { - flow_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000080); - } else { - flowBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Issue_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Issue getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Issue.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Issue build() { - org.sonar.batch.protocol.output.BatchReport.Issue result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Issue buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Issue result = new org.sonar.batch.protocol.output.BatchReport.Issue(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.ruleRepository_ = ruleRepository_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.ruleKey_ = ruleKey_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.line_ = line_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.msg_ = msg_; - if (((from_bitField0_ & 0x00000010) == 0x00000010)) { - to_bitField0_ |= 0x00000010; - } - result.severity_ = severity_; - if (((from_bitField0_ & 0x00000020) == 0x00000020)) { - to_bitField0_ |= 0x00000020; - } - result.effortToFix_ = effortToFix_; - if (((from_bitField0_ & 0x00000040) == 0x00000040)) { - to_bitField0_ |= 0x00000040; - } - if (textRangeBuilder_ == null) { - result.textRange_ = textRange_; - } else { - result.textRange_ = textRangeBuilder_.build(); - } - if (flowBuilder_ == null) { - if (((bitField0_ & 0x00000080) == 0x00000080)) { - flow_ = java.util.Collections.unmodifiableList(flow_); - bitField0_ = (bitField0_ & ~0x00000080); - } - result.flow_ = flow_; - } else { - result.flow_ = flowBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Issue) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Issue)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Issue other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Issue.getDefaultInstance()) return this; - if (other.hasRuleRepository()) { - bitField0_ |= 0x00000001; - ruleRepository_ = other.ruleRepository_; - onChanged(); - } - if (other.hasRuleKey()) { - bitField0_ |= 0x00000002; - ruleKey_ = other.ruleKey_; - onChanged(); - } - if (other.hasLine()) { - setLine(other.getLine()); - } - if (other.hasMsg()) { - bitField0_ |= 0x00000008; - msg_ = other.msg_; - onChanged(); - } - if (other.hasSeverity()) { - setSeverity(other.getSeverity()); - } - if (other.hasEffortToFix()) { - setEffortToFix(other.getEffortToFix()); - } - if (other.hasTextRange()) { - mergeTextRange(other.getTextRange()); - } - if (flowBuilder_ == null) { - if (!other.flow_.isEmpty()) { - if (flow_.isEmpty()) { - flow_ = other.flow_; - bitField0_ = (bitField0_ & ~0x00000080); - } else { - ensureFlowIsMutable(); - flow_.addAll(other.flow_); - } - onChanged(); - } - } else { - if (!other.flow_.isEmpty()) { - if (flowBuilder_.isEmpty()) { - flowBuilder_.dispose(); - flowBuilder_ = null; - flow_ = other.flow_; - bitField0_ = (bitField0_ & ~0x00000080); - flowBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getFlowFieldBuilder() : null; - } else { - flowBuilder_.addAllMessages(other.flow_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Issue parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Issue) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object ruleRepository_ = ""; - /** - * <code>optional string rule_repository = 1;</code> - */ - public boolean hasRuleRepository() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public java.lang.String getRuleRepository() { - java.lang.Object ref = ruleRepository_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleRepository_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public com.google.protobuf.ByteString - getRuleRepositoryBytes() { - java.lang.Object ref = ruleRepository_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleRepository_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public Builder setRuleRepository( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - ruleRepository_ = value; - onChanged(); - return this; - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public Builder clearRuleRepository() { - bitField0_ = (bitField0_ & ~0x00000001); - ruleRepository_ = getDefaultInstance().getRuleRepository(); - onChanged(); - return this; - } - /** - * <code>optional string rule_repository = 1;</code> - */ - public Builder setRuleRepositoryBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - ruleRepository_ = value; - onChanged(); - return this; - } - - private java.lang.Object ruleKey_ = ""; - /** - * <code>optional string rule_key = 2;</code> - */ - public boolean hasRuleKey() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string rule_key = 2;</code> - */ - public java.lang.String getRuleKey() { - java.lang.Object ref = ruleKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - ruleKey_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string rule_key = 2;</code> - */ - public com.google.protobuf.ByteString - getRuleKeyBytes() { - java.lang.Object ref = ruleKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - ruleKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string rule_key = 2;</code> - */ - public Builder setRuleKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - ruleKey_ = value; - onChanged(); - return this; - } - /** - * <code>optional string rule_key = 2;</code> - */ - public Builder clearRuleKey() { - bitField0_ = (bitField0_ & ~0x00000002); - ruleKey_ = getDefaultInstance().getRuleKey(); - onChanged(); - return this; - } - /** - * <code>optional string rule_key = 2;</code> - */ - public Builder setRuleKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - ruleKey_ = value; - onChanged(); - return this; - } - - private int line_ ; - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - public boolean hasLine() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - public int getLine() { - return line_; - } - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - public Builder setLine(int value) { - bitField0_ |= 0x00000004; - line_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 line = 3;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - *TODO To be removed. Use first line of text_range instead - * </pre> - */ - public Builder clearLine() { - bitField0_ = (bitField0_ & ~0x00000004); - line_ = 0; - onChanged(); - return this; - } - - private java.lang.Object msg_ = ""; - /** - * <code>optional string msg = 4;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional string msg = 4;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string msg = 4;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string msg = 4;</code> - */ - public Builder setMsg( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - msg_ = value; - onChanged(); - return this; - } - /** - * <code>optional string msg = 4;</code> - */ - public Builder clearMsg() { - bitField0_ = (bitField0_ & ~0x00000008); - msg_ = getDefaultInstance().getMsg(); - onChanged(); - return this; - } - /** - * <code>optional string msg = 4;</code> - */ - public Builder setMsgBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - msg_ = value; - onChanged(); - return this; - } - - private int severity_ = 0; - /** - * <code>optional .Severity severity = 5;</code> - */ - public boolean hasSeverity() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional .Severity severity = 5;</code> - */ - public org.sonar.batch.protocol.Constants.Severity getSeverity() { - org.sonar.batch.protocol.Constants.Severity result = org.sonar.batch.protocol.Constants.Severity.valueOf(severity_); - return result == null ? org.sonar.batch.protocol.Constants.Severity.INFO : result; - } - /** - * <code>optional .Severity severity = 5;</code> - */ - public Builder setSeverity(org.sonar.batch.protocol.Constants.Severity value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000010; - severity_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .Severity severity = 5;</code> - */ - public Builder clearSeverity() { - bitField0_ = (bitField0_ & ~0x00000010); - severity_ = 0; - onChanged(); - return this; - } - - private double effortToFix_ ; - /** - * <code>optional double effort_to_fix = 6;</code> - */ - public boolean hasEffortToFix() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional double effort_to_fix = 6;</code> - */ - public double getEffortToFix() { - return effortToFix_; - } - /** - * <code>optional double effort_to_fix = 6;</code> - */ - public Builder setEffortToFix(double value) { - bitField0_ |= 0x00000020; - effortToFix_ = value; - onChanged(); - return this; - } - /** - * <code>optional double effort_to_fix = 6;</code> - */ - public Builder clearEffortToFix() { - bitField0_ = (bitField0_ & ~0x00000020); - effortToFix_ = 0D; - onChanged(); - return this; - } - - private org.sonar.batch.protocol.output.BatchReport.TextRange textRange_ = null; - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> textRangeBuilder_; - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public boolean hasTextRange() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getTextRange() { - if (textRangeBuilder_ == null) { - return textRange_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } else { - return textRangeBuilder_.getMessage(); - } - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder setTextRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (textRangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - textRange_ = value; - onChanged(); - } else { - textRangeBuilder_.setMessage(value); - } - bitField0_ |= 0x00000040; - return this; - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder setTextRange( - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (textRangeBuilder_ == null) { - textRange_ = builderForValue.build(); - onChanged(); - } else { - textRangeBuilder_.setMessage(builderForValue.build()); - } - bitField0_ |= 0x00000040; - return this; - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder mergeTextRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (textRangeBuilder_ == null) { - if (((bitField0_ & 0x00000040) == 0x00000040) && - textRange_ != null && - textRange_ != org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()) { - textRange_ = - org.sonar.batch.protocol.output.BatchReport.TextRange.newBuilder(textRange_).mergeFrom(value).buildPartial(); - } else { - textRange_ = value; - } - onChanged(); - } else { - textRangeBuilder_.mergeFrom(value); - } - bitField0_ |= 0x00000040; - return this; - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder clearTextRange() { - if (textRangeBuilder_ == null) { - textRange_ = null; - onChanged(); - } else { - textRangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000040); - return this; - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder getTextRangeBuilder() { - bitField0_ |= 0x00000040; - onChanged(); - return getTextRangeFieldBuilder().getBuilder(); - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getTextRangeOrBuilder() { - if (textRangeBuilder_ != null) { - return textRangeBuilder_.getMessageOrBuilder(); - } else { - return textRange_ == null ? - org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } - } - /** - * <code>optional .TextRange text_range = 7;</code> - * - * <pre> - * Only when issue component is a file. Can also be empty for a file if this is an issue global to the file. - * </pre> - */ - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getTextRangeFieldBuilder() { - if (textRangeBuilder_ == null) { - textRangeBuilder_ = new com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder>( - getTextRange(), - getParentForChildren(), - isClean()); - textRange_ = null; - } - return textRangeBuilder_; - } - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.Flow> flow_ = - java.util.Collections.emptyList(); - private void ensureFlowIsMutable() { - if (!((bitField0_ & 0x00000080) == 0x00000080)) { - flow_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.Flow>(flow_); - bitField0_ |= 0x00000080; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Flow, org.sonar.batch.protocol.output.BatchReport.Flow.Builder, org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder> flowBuilder_; - - /** - * <code>repeated .Flow flow = 8;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Flow> getFlowList() { - if (flowBuilder_ == null) { - return java.util.Collections.unmodifiableList(flow_); - } else { - return flowBuilder_.getMessageList(); - } - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public int getFlowCount() { - if (flowBuilder_ == null) { - return flow_.size(); - } else { - return flowBuilder_.getCount(); - } - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Flow getFlow(int index) { - if (flowBuilder_ == null) { - return flow_.get(index); - } else { - return flowBuilder_.getMessage(index); - } - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder setFlow( - int index, org.sonar.batch.protocol.output.BatchReport.Flow value) { - if (flowBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFlowIsMutable(); - flow_.set(index, value); - onChanged(); - } else { - flowBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder setFlow( - int index, org.sonar.batch.protocol.output.BatchReport.Flow.Builder builderForValue) { - if (flowBuilder_ == null) { - ensureFlowIsMutable(); - flow_.set(index, builderForValue.build()); - onChanged(); - } else { - flowBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder addFlow(org.sonar.batch.protocol.output.BatchReport.Flow value) { - if (flowBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFlowIsMutable(); - flow_.add(value); - onChanged(); - } else { - flowBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder addFlow( - int index, org.sonar.batch.protocol.output.BatchReport.Flow value) { - if (flowBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFlowIsMutable(); - flow_.add(index, value); - onChanged(); - } else { - flowBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder addFlow( - org.sonar.batch.protocol.output.BatchReport.Flow.Builder builderForValue) { - if (flowBuilder_ == null) { - ensureFlowIsMutable(); - flow_.add(builderForValue.build()); - onChanged(); - } else { - flowBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder addFlow( - int index, org.sonar.batch.protocol.output.BatchReport.Flow.Builder builderForValue) { - if (flowBuilder_ == null) { - ensureFlowIsMutable(); - flow_.add(index, builderForValue.build()); - onChanged(); - } else { - flowBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder addAllFlow( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.Flow> values) { - if (flowBuilder_ == null) { - ensureFlowIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, flow_); - onChanged(); - } else { - flowBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder clearFlow() { - if (flowBuilder_ == null) { - flow_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000080); - onChanged(); - } else { - flowBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public Builder removeFlow(int index) { - if (flowBuilder_ == null) { - ensureFlowIsMutable(); - flow_.remove(index); - onChanged(); - } else { - flowBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Flow.Builder getFlowBuilder( - int index) { - return getFlowFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder getFlowOrBuilder( - int index) { - if (flowBuilder_ == null) { - return flow_.get(index); } else { - return flowBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder> - getFlowOrBuilderList() { - if (flowBuilder_ != null) { - return flowBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(flow_); - } - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Flow.Builder addFlowBuilder() { - return getFlowFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.Flow.getDefaultInstance()); - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Flow.Builder addFlowBuilder( - int index) { - return getFlowFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.Flow.getDefaultInstance()); - } - /** - * <code>repeated .Flow flow = 8;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Flow.Builder> - getFlowBuilderList() { - return getFlowFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Flow, org.sonar.batch.protocol.output.BatchReport.Flow.Builder, org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder> - getFlowFieldBuilder() { - if (flowBuilder_ == null) { - flowBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Flow, org.sonar.batch.protocol.output.BatchReport.Flow.Builder, org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder>( - flow_, - ((bitField0_ & 0x00000080) == 0x00000080), - getParentForChildren(), - isClean()); - flow_ = null; - } - return flowBuilder_; - } - - // @@protoc_insertion_point(builder_scope:Issue) - } - - // @@protoc_insertion_point(class_scope:Issue) - private static final org.sonar.batch.protocol.output.BatchReport.Issue DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Issue(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Issue getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Issue> PARSER = - new com.google.protobuf.AbstractParser<Issue>() { - public Issue parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Issue(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Issue> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Issue getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface IssueLocationOrBuilder extends - // @@protoc_insertion_point(interface_extends:IssueLocation) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int32 component_ref = 1;</code> - */ - boolean hasComponentRef(); - /** - * <code>optional int32 component_ref = 1;</code> - */ - int getComponentRef(); - - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - boolean hasTextRange(); - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - org.sonar.batch.protocol.output.BatchReport.TextRange getTextRange(); - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getTextRangeOrBuilder(); - - /** - * <code>optional string msg = 3;</code> - */ - boolean hasMsg(); - /** - * <code>optional string msg = 3;</code> - */ - java.lang.String getMsg(); - /** - * <code>optional string msg = 3;</code> - */ - com.google.protobuf.ByteString - getMsgBytes(); - } - /** - * Protobuf type {@code IssueLocation} - */ - public static final class IssueLocation extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:IssueLocation) - IssueLocationOrBuilder { - // Use IssueLocation.newBuilder() to construct. - private IssueLocation(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private IssueLocation() { - componentRef_ = 0; - msg_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private IssueLocation( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - componentRef_ = input.readInt32(); - break; - } - case 18: { - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder subBuilder = null; - if (((bitField0_ & 0x00000002) == 0x00000002)) { - subBuilder = textRange_.toBuilder(); - } - textRange_ = input.readMessage(org.sonar.batch.protocol.output.BatchReport.TextRange.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(textRange_); - textRange_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000002; - break; - } - case 26: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000004; - msg_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_IssueLocation_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_IssueLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.IssueLocation.class, org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder.class); - } - - private int bitField0_; - public static final int COMPONENT_REF_FIELD_NUMBER = 1; - private int componentRef_; - /** - * <code>optional int32 component_ref = 1;</code> - */ - public boolean hasComponentRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public int getComponentRef() { - return componentRef_; - } - - public static final int TEXT_RANGE_FIELD_NUMBER = 2; - private org.sonar.batch.protocol.output.BatchReport.TextRange textRange_; - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public boolean hasTextRange() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getTextRange() { - return textRange_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getTextRangeOrBuilder() { - return textRange_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } - - public static final int MSG_FIELD_NUMBER = 3; - private volatile java.lang.Object msg_; - /** - * <code>optional string msg = 3;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string msg = 3;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } - } - /** - * <code>optional string msg = 3;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt32(1, componentRef_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeMessage(2, getTextRange()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeBytes(3, getMsgBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, componentRef_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getTextRange()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(3, getMsgBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.IssueLocation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code IssueLocation} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:IssueLocation) - org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_IssueLocation_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_IssueLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.IssueLocation.class, org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.IssueLocation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getTextRangeFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - componentRef_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - if (textRangeBuilder_ == null) { - textRange_ = null; - } else { - textRangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000002); - msg_ = ""; - bitField0_ = (bitField0_ & ~0x00000004); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_IssueLocation_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.IssueLocation getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.IssueLocation.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.IssueLocation build() { - org.sonar.batch.protocol.output.BatchReport.IssueLocation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.IssueLocation buildPartial() { - org.sonar.batch.protocol.output.BatchReport.IssueLocation result = new org.sonar.batch.protocol.output.BatchReport.IssueLocation(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.componentRef_ = componentRef_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - if (textRangeBuilder_ == null) { - result.textRange_ = textRange_; - } else { - result.textRange_ = textRangeBuilder_.build(); - } - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.msg_ = msg_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.IssueLocation) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.IssueLocation)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.IssueLocation other) { - if (other == org.sonar.batch.protocol.output.BatchReport.IssueLocation.getDefaultInstance()) return this; - if (other.hasComponentRef()) { - setComponentRef(other.getComponentRef()); - } - if (other.hasTextRange()) { - mergeTextRange(other.getTextRange()); - } - if (other.hasMsg()) { - bitField0_ |= 0x00000004; - msg_ = other.msg_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.IssueLocation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.IssueLocation) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int componentRef_ ; - /** - * <code>optional int32 component_ref = 1;</code> - */ - public boolean hasComponentRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public int getComponentRef() { - return componentRef_; - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public Builder setComponentRef(int value) { - bitField0_ |= 0x00000001; - componentRef_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public Builder clearComponentRef() { - bitField0_ = (bitField0_ & ~0x00000001); - componentRef_ = 0; - onChanged(); - return this; - } - - private org.sonar.batch.protocol.output.BatchReport.TextRange textRange_ = null; - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> textRangeBuilder_; - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public boolean hasTextRange() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getTextRange() { - if (textRangeBuilder_ == null) { - return textRange_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } else { - return textRangeBuilder_.getMessage(); - } - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder setTextRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (textRangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - textRange_ = value; - onChanged(); - } else { - textRangeBuilder_.setMessage(value); - } - bitField0_ |= 0x00000002; - return this; - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder setTextRange( - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (textRangeBuilder_ == null) { - textRange_ = builderForValue.build(); - onChanged(); - } else { - textRangeBuilder_.setMessage(builderForValue.build()); - } - bitField0_ |= 0x00000002; - return this; - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder mergeTextRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (textRangeBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002) && - textRange_ != null && - textRange_ != org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()) { - textRange_ = - org.sonar.batch.protocol.output.BatchReport.TextRange.newBuilder(textRange_).mergeFrom(value).buildPartial(); - } else { - textRange_ = value; - } - onChanged(); - } else { - textRangeBuilder_.mergeFrom(value); - } - bitField0_ |= 0x00000002; - return this; - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public Builder clearTextRange() { - if (textRangeBuilder_ == null) { - textRange_ = null; - onChanged(); - } else { - textRangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder getTextRangeBuilder() { - bitField0_ |= 0x00000002; - onChanged(); - return getTextRangeFieldBuilder().getBuilder(); - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getTextRangeOrBuilder() { - if (textRangeBuilder_ != null) { - return textRangeBuilder_.getMessageOrBuilder(); - } else { - return textRange_ == null ? - org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : textRange_; - } - } - /** - * <code>optional .TextRange text_range = 2;</code> - * - * <pre> - * Only when component is a file. Can be empty for a file if this is an issue global to the file. - * </pre> - */ - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getTextRangeFieldBuilder() { - if (textRangeBuilder_ == null) { - textRangeBuilder_ = new com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder>( - getTextRange(), - getParentForChildren(), - isClean()); - textRange_ = null; - } - return textRangeBuilder_; - } - - private java.lang.Object msg_ = ""; - /** - * <code>optional string msg = 3;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string msg = 3;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string msg = 3;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string msg = 3;</code> - */ - public Builder setMsg( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - msg_ = value; - onChanged(); - return this; - } - /** - * <code>optional string msg = 3;</code> - */ - public Builder clearMsg() { - bitField0_ = (bitField0_ & ~0x00000004); - msg_ = getDefaultInstance().getMsg(); - onChanged(); - return this; - } - /** - * <code>optional string msg = 3;</code> - */ - public Builder setMsgBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - msg_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:IssueLocation) - } - - // @@protoc_insertion_point(class_scope:IssueLocation) - private static final org.sonar.batch.protocol.output.BatchReport.IssueLocation DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.IssueLocation(); - } - - public static org.sonar.batch.protocol.output.BatchReport.IssueLocation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<IssueLocation> PARSER = - new com.google.protobuf.AbstractParser<IssueLocation>() { - public IssueLocation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new IssueLocation(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<IssueLocation> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.IssueLocation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface FlowOrBuilder extends - // @@protoc_insertion_point(interface_extends:Flow) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.IssueLocation> - getLocationList(); - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - org.sonar.batch.protocol.output.BatchReport.IssueLocation getLocation(int index); - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - int getLocationCount(); - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder> - getLocationOrBuilderList(); - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder getLocationOrBuilder( - int index); - } - /** - * Protobuf type {@code Flow} - */ - public static final class Flow extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Flow) - FlowOrBuilder { - // Use Flow.newBuilder() to construct. - private Flow(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Flow() { - location_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Flow( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - location_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.IssueLocation>(); - mutable_bitField0_ |= 0x00000001; - } - location_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.IssueLocation.PARSER, extensionRegistry)); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - location_ = java.util.Collections.unmodifiableList(location_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Flow_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Flow_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Flow.class, org.sonar.batch.protocol.output.BatchReport.Flow.Builder.class); - } - - public static final int LOCATION_FIELD_NUMBER = 1; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.IssueLocation> location_; - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.IssueLocation> getLocationList() { - return location_; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder> - getLocationOrBuilderList() { - return location_; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public int getLocationCount() { - return location_.size(); - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.IssueLocation getLocation(int index) { - return location_.get(index); - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder getLocationOrBuilder( - int index) { - return location_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < location_.size(); i++) { - output.writeMessage(1, location_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < location_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, location_.get(i)); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Flow parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Flow prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Flow} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Flow) - org.sonar.batch.protocol.output.BatchReport.FlowOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Flow_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Flow_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Flow.class, org.sonar.batch.protocol.output.BatchReport.Flow.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Flow.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getLocationFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (locationBuilder_ == null) { - location_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - locationBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Flow_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Flow getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Flow.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Flow build() { - org.sonar.batch.protocol.output.BatchReport.Flow result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Flow buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Flow result = new org.sonar.batch.protocol.output.BatchReport.Flow(this); - int from_bitField0_ = bitField0_; - if (locationBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - location_ = java.util.Collections.unmodifiableList(location_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.location_ = location_; - } else { - result.location_ = locationBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Flow) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Flow)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Flow other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Flow.getDefaultInstance()) return this; - if (locationBuilder_ == null) { - if (!other.location_.isEmpty()) { - if (location_.isEmpty()) { - location_ = other.location_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureLocationIsMutable(); - location_.addAll(other.location_); - } - onChanged(); - } - } else { - if (!other.location_.isEmpty()) { - if (locationBuilder_.isEmpty()) { - locationBuilder_.dispose(); - locationBuilder_ = null; - location_ = other.location_; - bitField0_ = (bitField0_ & ~0x00000001); - locationBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getLocationFieldBuilder() : null; - } else { - locationBuilder_.addAllMessages(other.location_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Flow parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Flow) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.IssueLocation> location_ = - java.util.Collections.emptyList(); - private void ensureLocationIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - location_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.IssueLocation>(location_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.IssueLocation, org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder, org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder> locationBuilder_; - - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.IssueLocation> getLocationList() { - if (locationBuilder_ == null) { - return java.util.Collections.unmodifiableList(location_); - } else { - return locationBuilder_.getMessageList(); - } - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public int getLocationCount() { - if (locationBuilder_ == null) { - return location_.size(); - } else { - return locationBuilder_.getCount(); - } - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.IssueLocation getLocation(int index) { - if (locationBuilder_ == null) { - return location_.get(index); - } else { - return locationBuilder_.getMessage(index); - } - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder setLocation( - int index, org.sonar.batch.protocol.output.BatchReport.IssueLocation value) { - if (locationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLocationIsMutable(); - location_.set(index, value); - onChanged(); - } else { - locationBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder setLocation( - int index, org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder builderForValue) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.set(index, builderForValue.build()); - onChanged(); - } else { - locationBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder addLocation(org.sonar.batch.protocol.output.BatchReport.IssueLocation value) { - if (locationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLocationIsMutable(); - location_.add(value); - onChanged(); - } else { - locationBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder addLocation( - int index, org.sonar.batch.protocol.output.BatchReport.IssueLocation value) { - if (locationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureLocationIsMutable(); - location_.add(index, value); - onChanged(); - } else { - locationBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder addLocation( - org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder builderForValue) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.add(builderForValue.build()); - onChanged(); - } else { - locationBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder addLocation( - int index, org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder builderForValue) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.add(index, builderForValue.build()); - onChanged(); - } else { - locationBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder addAllLocation( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.IssueLocation> values) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, location_); - onChanged(); - } else { - locationBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder clearLocation() { - if (locationBuilder_ == null) { - location_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - locationBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public Builder removeLocation(int index) { - if (locationBuilder_ == null) { - ensureLocationIsMutable(); - location_.remove(index); - onChanged(); - } else { - locationBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder getLocationBuilder( - int index) { - return getLocationFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder getLocationOrBuilder( - int index) { - if (locationBuilder_ == null) { - return location_.get(index); } else { - return locationBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder> - getLocationOrBuilderList() { - if (locationBuilder_ != null) { - return locationBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(location_); - } - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder addLocationBuilder() { - return getLocationFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.IssueLocation.getDefaultInstance()); - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder addLocationBuilder( - int index) { - return getLocationFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.IssueLocation.getDefaultInstance()); - } - /** - * <code>repeated .IssueLocation location = 1;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder> - getLocationBuilderList() { - return getLocationFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.IssueLocation, org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder, org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder> - getLocationFieldBuilder() { - if (locationBuilder_ == null) { - locationBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.IssueLocation, org.sonar.batch.protocol.output.BatchReport.IssueLocation.Builder, org.sonar.batch.protocol.output.BatchReport.IssueLocationOrBuilder>( - location_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - location_ = null; - } - return locationBuilder_; - } - - // @@protoc_insertion_point(builder_scope:Flow) - } - - // @@protoc_insertion_point(class_scope:Flow) - private static final org.sonar.batch.protocol.output.BatchReport.Flow DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Flow(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Flow getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Flow> PARSER = - new com.google.protobuf.AbstractParser<Flow>() { - public Flow parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Flow(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Flow> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Flow getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ChangesetsOrBuilder extends - // @@protoc_insertion_point(interface_extends:Changesets) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int32 component_ref = 1;</code> - */ - boolean hasComponentRef(); - /** - * <code>optional int32 component_ref = 1;</code> - */ - int getComponentRef(); - - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset> - getChangesetList(); - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset getChangeset(int index); - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - int getChangesetCount(); - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder> - getChangesetOrBuilderList(); - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder getChangesetOrBuilder( - int index); - - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - java.util.List<java.lang.Integer> getChangesetIndexByLineList(); - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - int getChangesetIndexByLineCount(); - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - int getChangesetIndexByLine(int index); - } - /** - * Protobuf type {@code Changesets} - */ - public static final class Changesets extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Changesets) - ChangesetsOrBuilder { - // Use Changesets.newBuilder() to construct. - private Changesets(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Changesets() { - componentRef_ = 0; - changeset_ = java.util.Collections.emptyList(); - changesetIndexByLine_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Changesets( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - componentRef_ = input.readInt32(); - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - changeset_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset>(); - mutable_bitField0_ |= 0x00000002; - } - changeset_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.PARSER, extensionRegistry)); - break; - } - case 24: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - changesetIndexByLine_ = new java.util.ArrayList<java.lang.Integer>(); - mutable_bitField0_ |= 0x00000004; - } - changesetIndexByLine_.add(input.readInt32()); - break; - } - case 26: { - int length = input.readRawVarint32(); - int limit = input.pushLimit(length); - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004) && input.getBytesUntilLimit() > 0) { - changesetIndexByLine_ = new java.util.ArrayList<java.lang.Integer>(); - mutable_bitField0_ |= 0x00000004; - } - while (input.getBytesUntilLimit() > 0) { - changesetIndexByLine_.add(input.readInt32()); - } - input.popLimit(limit); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - changeset_ = java.util.Collections.unmodifiableList(changeset_); - } - if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - changesetIndexByLine_ = java.util.Collections.unmodifiableList(changesetIndexByLine_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Changesets.class, org.sonar.batch.protocol.output.BatchReport.Changesets.Builder.class); - } - - public interface ChangesetOrBuilder extends - // @@protoc_insertion_point(interface_extends:Changesets.Changeset) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string revision = 1;</code> - */ - boolean hasRevision(); - /** - * <code>optional string revision = 1;</code> - */ - java.lang.String getRevision(); - /** - * <code>optional string revision = 1;</code> - */ - com.google.protobuf.ByteString - getRevisionBytes(); - - /** - * <code>optional string author = 2;</code> - */ - boolean hasAuthor(); - /** - * <code>optional string author = 2;</code> - */ - java.lang.String getAuthor(); - /** - * <code>optional string author = 2;</code> - */ - com.google.protobuf.ByteString - getAuthorBytes(); - - /** - * <code>optional int64 date = 3;</code> - */ - boolean hasDate(); - /** - * <code>optional int64 date = 3;</code> - */ - long getDate(); - } - /** - * Protobuf type {@code Changesets.Changeset} - */ - public static final class Changeset extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Changesets.Changeset) - ChangesetOrBuilder { - // Use Changeset.newBuilder() to construct. - private Changeset(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Changeset() { - revision_ = ""; - author_ = ""; - date_ = 0L; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Changeset( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - revision_ = bs; - break; - } - case 18: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000002; - author_ = bs; - break; - } - case 24: { - bitField0_ |= 0x00000004; - date_ = input.readInt64(); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_Changeset_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_Changeset_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.class, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder.class); - } - - private int bitField0_; - public static final int REVISION_FIELD_NUMBER = 1; - private volatile java.lang.Object revision_; - /** - * <code>optional string revision = 1;</code> - */ - public boolean hasRevision() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string revision = 1;</code> - */ - public java.lang.String getRevision() { - java.lang.Object ref = revision_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - revision_ = s; - } - return s; - } - } - /** - * <code>optional string revision = 1;</code> - */ - public com.google.protobuf.ByteString - getRevisionBytes() { - java.lang.Object ref = revision_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - revision_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int AUTHOR_FIELD_NUMBER = 2; - private volatile java.lang.Object author_; - /** - * <code>optional string author = 2;</code> - */ - public boolean hasAuthor() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string author = 2;</code> - */ - public java.lang.String getAuthor() { - java.lang.Object ref = author_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - author_ = s; - } - return s; - } - } - /** - * <code>optional string author = 2;</code> - */ - public com.google.protobuf.ByteString - getAuthorBytes() { - java.lang.Object ref = author_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - author_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DATE_FIELD_NUMBER = 3; - private long date_; - /** - * <code>optional int64 date = 3;</code> - */ - public boolean hasDate() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int64 date = 3;</code> - */ - public long getDate() { - return date_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getRevisionBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getAuthorBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeInt64(3, date_); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getRevisionBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getAuthorBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(3, date_); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Changesets.Changeset} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Changesets.Changeset) - org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_Changeset_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_Changeset_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.class, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - revision_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - author_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - date_ = 0L; - bitField0_ = (bitField0_ & ~0x00000004); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_Changeset_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset build() { - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset result = new org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.revision_ = revision_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.author_ = author_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.date_ = date_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.getDefaultInstance()) return this; - if (other.hasRevision()) { - bitField0_ |= 0x00000001; - revision_ = other.revision_; - onChanged(); - } - if (other.hasAuthor()) { - bitField0_ |= 0x00000002; - author_ = other.author_; - onChanged(); - } - if (other.hasDate()) { - setDate(other.getDate()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object revision_ = ""; - /** - * <code>optional string revision = 1;</code> - */ - public boolean hasRevision() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string revision = 1;</code> - */ - public java.lang.String getRevision() { - java.lang.Object ref = revision_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - revision_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string revision = 1;</code> - */ - public com.google.protobuf.ByteString - getRevisionBytes() { - java.lang.Object ref = revision_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - revision_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string revision = 1;</code> - */ - public Builder setRevision( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - revision_ = value; - onChanged(); - return this; - } - /** - * <code>optional string revision = 1;</code> - */ - public Builder clearRevision() { - bitField0_ = (bitField0_ & ~0x00000001); - revision_ = getDefaultInstance().getRevision(); - onChanged(); - return this; - } - /** - * <code>optional string revision = 1;</code> - */ - public Builder setRevisionBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - revision_ = value; - onChanged(); - return this; - } - - private java.lang.Object author_ = ""; - /** - * <code>optional string author = 2;</code> - */ - public boolean hasAuthor() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional string author = 2;</code> - */ - public java.lang.String getAuthor() { - java.lang.Object ref = author_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - author_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string author = 2;</code> - */ - public com.google.protobuf.ByteString - getAuthorBytes() { - java.lang.Object ref = author_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - author_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string author = 2;</code> - */ - public Builder setAuthor( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - author_ = value; - onChanged(); - return this; - } - /** - * <code>optional string author = 2;</code> - */ - public Builder clearAuthor() { - bitField0_ = (bitField0_ & ~0x00000002); - author_ = getDefaultInstance().getAuthor(); - onChanged(); - return this; - } - /** - * <code>optional string author = 2;</code> - */ - public Builder setAuthorBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - author_ = value; - onChanged(); - return this; - } - - private long date_ ; - /** - * <code>optional int64 date = 3;</code> - */ - public boolean hasDate() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int64 date = 3;</code> - */ - public long getDate() { - return date_; - } - /** - * <code>optional int64 date = 3;</code> - */ - public Builder setDate(long value) { - bitField0_ |= 0x00000004; - date_ = value; - onChanged(); - return this; - } - /** - * <code>optional int64 date = 3;</code> - */ - public Builder clearDate() { - bitField0_ = (bitField0_ & ~0x00000004); - date_ = 0L; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Changesets.Changeset) - } - - // @@protoc_insertion_point(class_scope:Changesets.Changeset) - private static final org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Changeset> PARSER = - new com.google.protobuf.AbstractParser<Changeset>() { - public Changeset parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Changeset(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Changeset> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int bitField0_; - public static final int COMPONENT_REF_FIELD_NUMBER = 1; - private int componentRef_; - /** - * <code>optional int32 component_ref = 1;</code> - */ - public boolean hasComponentRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public int getComponentRef() { - return componentRef_; - } - - public static final int CHANGESET_FIELD_NUMBER = 2; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset> changeset_; - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset> getChangesetList() { - return changeset_; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder> - getChangesetOrBuilderList() { - return changeset_; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public int getChangesetCount() { - return changeset_.size(); - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset getChangeset(int index) { - return changeset_.get(index); - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder getChangesetOrBuilder( - int index) { - return changeset_.get(index); - } - - public static final int CHANGESETINDEXBYLINE_FIELD_NUMBER = 3; - private java.util.List<java.lang.Integer> changesetIndexByLine_; - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public java.util.List<java.lang.Integer> - getChangesetIndexByLineList() { - return changesetIndexByLine_; - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public int getChangesetIndexByLineCount() { - return changesetIndexByLine_.size(); - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public int getChangesetIndexByLine(int index) { - return changesetIndexByLine_.get(index); - } - private int changesetIndexByLineMemoizedSerializedSize = -1; - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - getSerializedSize(); - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt32(1, componentRef_); - } - for (int i = 0; i < changeset_.size(); i++) { - output.writeMessage(2, changeset_.get(i)); - } - if (getChangesetIndexByLineList().size() > 0) { - output.writeRawVarint32(26); - output.writeRawVarint32(changesetIndexByLineMemoizedSerializedSize); - } - for (int i = 0; i < changesetIndexByLine_.size(); i++) { - output.writeInt32NoTag(changesetIndexByLine_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, componentRef_); - } - for (int i = 0; i < changeset_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, changeset_.get(i)); - } - { - int dataSize = 0; - for (int i = 0; i < changesetIndexByLine_.size(); i++) { - dataSize += com.google.protobuf.CodedOutputStream - .computeInt32SizeNoTag(changesetIndexByLine_.get(i)); - } - size += dataSize; - if (!getChangesetIndexByLineList().isEmpty()) { - size += 1; - size += com.google.protobuf.CodedOutputStream - .computeInt32SizeNoTag(dataSize); - } - changesetIndexByLineMemoizedSerializedSize = dataSize; - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Changesets parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Changesets prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Changesets} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Changesets) - org.sonar.batch.protocol.output.BatchReport.ChangesetsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Changesets.class, org.sonar.batch.protocol.output.BatchReport.Changesets.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Changesets.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getChangesetFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - componentRef_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - if (changesetBuilder_ == null) { - changeset_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - changesetBuilder_.clear(); - } - changesetIndexByLine_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Changesets_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Changesets.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets build() { - org.sonar.batch.protocol.output.BatchReport.Changesets result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Changesets result = new org.sonar.batch.protocol.output.BatchReport.Changesets(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.componentRef_ = componentRef_; - if (changesetBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - changeset_ = java.util.Collections.unmodifiableList(changeset_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.changeset_ = changeset_; - } else { - result.changeset_ = changesetBuilder_.build(); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - changesetIndexByLine_ = java.util.Collections.unmodifiableList(changesetIndexByLine_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.changesetIndexByLine_ = changesetIndexByLine_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Changesets) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Changesets)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Changesets other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Changesets.getDefaultInstance()) return this; - if (other.hasComponentRef()) { - setComponentRef(other.getComponentRef()); - } - if (changesetBuilder_ == null) { - if (!other.changeset_.isEmpty()) { - if (changeset_.isEmpty()) { - changeset_ = other.changeset_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureChangesetIsMutable(); - changeset_.addAll(other.changeset_); - } - onChanged(); - } - } else { - if (!other.changeset_.isEmpty()) { - if (changesetBuilder_.isEmpty()) { - changesetBuilder_.dispose(); - changesetBuilder_ = null; - changeset_ = other.changeset_; - bitField0_ = (bitField0_ & ~0x00000002); - changesetBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getChangesetFieldBuilder() : null; - } else { - changesetBuilder_.addAllMessages(other.changeset_); - } - } - } - if (!other.changesetIndexByLine_.isEmpty()) { - if (changesetIndexByLine_.isEmpty()) { - changesetIndexByLine_ = other.changesetIndexByLine_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureChangesetIndexByLineIsMutable(); - changesetIndexByLine_.addAll(other.changesetIndexByLine_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Changesets parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Changesets) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int componentRef_ ; - /** - * <code>optional int32 component_ref = 1;</code> - */ - public boolean hasComponentRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public int getComponentRef() { - return componentRef_; - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public Builder setComponentRef(int value) { - bitField0_ |= 0x00000001; - componentRef_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 component_ref = 1;</code> - */ - public Builder clearComponentRef() { - bitField0_ = (bitField0_ & ~0x00000001); - componentRef_ = 0; - onChanged(); - return this; - } - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset> changeset_ = - java.util.Collections.emptyList(); - private void ensureChangesetIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - changeset_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset>(changeset_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder, org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder> changesetBuilder_; - - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset> getChangesetList() { - if (changesetBuilder_ == null) { - return java.util.Collections.unmodifiableList(changeset_); - } else { - return changesetBuilder_.getMessageList(); - } - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public int getChangesetCount() { - if (changesetBuilder_ == null) { - return changeset_.size(); - } else { - return changesetBuilder_.getCount(); - } - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset getChangeset(int index) { - if (changesetBuilder_ == null) { - return changeset_.get(index); - } else { - return changesetBuilder_.getMessage(index); - } - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder setChangeset( - int index, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset value) { - if (changesetBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureChangesetIsMutable(); - changeset_.set(index, value); - onChanged(); - } else { - changesetBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder setChangeset( - int index, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder builderForValue) { - if (changesetBuilder_ == null) { - ensureChangesetIsMutable(); - changeset_.set(index, builderForValue.build()); - onChanged(); - } else { - changesetBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder addChangeset(org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset value) { - if (changesetBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureChangesetIsMutable(); - changeset_.add(value); - onChanged(); - } else { - changesetBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder addChangeset( - int index, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset value) { - if (changesetBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureChangesetIsMutable(); - changeset_.add(index, value); - onChanged(); - } else { - changesetBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder addChangeset( - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder builderForValue) { - if (changesetBuilder_ == null) { - ensureChangesetIsMutable(); - changeset_.add(builderForValue.build()); - onChanged(); - } else { - changesetBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder addChangeset( - int index, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder builderForValue) { - if (changesetBuilder_ == null) { - ensureChangesetIsMutable(); - changeset_.add(index, builderForValue.build()); - onChanged(); - } else { - changesetBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder addAllChangeset( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset> values) { - if (changesetBuilder_ == null) { - ensureChangesetIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, changeset_); - onChanged(); - } else { - changesetBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder clearChangeset() { - if (changesetBuilder_ == null) { - changeset_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - changesetBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public Builder removeChangeset(int index) { - if (changesetBuilder_ == null) { - ensureChangesetIsMutable(); - changeset_.remove(index); - onChanged(); - } else { - changesetBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder getChangesetBuilder( - int index) { - return getChangesetFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder getChangesetOrBuilder( - int index) { - if (changesetBuilder_ == null) { - return changeset_.get(index); } else { - return changesetBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder> - getChangesetOrBuilderList() { - if (changesetBuilder_ != null) { - return changesetBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(changeset_); - } - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder addChangesetBuilder() { - return getChangesetFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.getDefaultInstance()); - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder addChangesetBuilder( - int index) { - return getChangesetFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.getDefaultInstance()); - } - /** - * <code>repeated .Changesets.Changeset changeset = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder> - getChangesetBuilderList() { - return getChangesetFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder, org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder> - getChangesetFieldBuilder() { - if (changesetBuilder_ == null) { - changesetBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset, org.sonar.batch.protocol.output.BatchReport.Changesets.Changeset.Builder, org.sonar.batch.protocol.output.BatchReport.Changesets.ChangesetOrBuilder>( - changeset_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - changeset_ = null; - } - return changesetBuilder_; - } - - private java.util.List<java.lang.Integer> changesetIndexByLine_ = java.util.Collections.emptyList(); - private void ensureChangesetIndexByLineIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - changesetIndexByLine_ = new java.util.ArrayList<java.lang.Integer>(changesetIndexByLine_); - bitField0_ |= 0x00000004; - } - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public java.util.List<java.lang.Integer> - getChangesetIndexByLineList() { - return java.util.Collections.unmodifiableList(changesetIndexByLine_); - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public int getChangesetIndexByLineCount() { - return changesetIndexByLine_.size(); - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public int getChangesetIndexByLine(int index) { - return changesetIndexByLine_.get(index); - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public Builder setChangesetIndexByLine( - int index, int value) { - ensureChangesetIndexByLineIsMutable(); - changesetIndexByLine_.set(index, value); - onChanged(); - return this; - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public Builder addChangesetIndexByLine(int value) { - ensureChangesetIndexByLineIsMutable(); - changesetIndexByLine_.add(value); - onChanged(); - return this; - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public Builder addAllChangesetIndexByLine( - java.lang.Iterable<? extends java.lang.Integer> values) { - ensureChangesetIndexByLineIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, changesetIndexByLine_); - onChanged(); - return this; - } - /** - * <code>repeated int32 changesetIndexByLine = 3 [packed = true];</code> - * - * <pre> - * if changesetIndexByLine[5] = 2 then it means that changeset[2] is the last one on line 6 - * </pre> - */ - public Builder clearChangesetIndexByLine() { - changesetIndexByLine_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Changesets) - } - - // @@protoc_insertion_point(class_scope:Changesets) - private static final org.sonar.batch.protocol.output.BatchReport.Changesets DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Changesets(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Changesets getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Changesets> PARSER = - new com.google.protobuf.AbstractParser<Changesets>() { - public Changesets parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Changesets(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Changesets> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Changesets getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface DuplicateOrBuilder extends - // @@protoc_insertion_point(interface_extends:Duplicate) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - boolean hasOtherFileRef(); - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - int getOtherFileRef(); - - /** - * <code>optional .TextRange range = 2;</code> - */ - boolean hasRange(); - /** - * <code>optional .TextRange range = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRange getRange(); - /** - * <code>optional .TextRange range = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getRangeOrBuilder(); - - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - boolean hasOtherFileKey(); - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - java.lang.String getOtherFileKey(); - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - com.google.protobuf.ByteString - getOtherFileKeyBytes(); - } - /** - * Protobuf type {@code Duplicate} - */ - public static final class Duplicate extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Duplicate) - DuplicateOrBuilder { - // Use Duplicate.newBuilder() to construct. - private Duplicate(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Duplicate() { - otherFileRef_ = 0; - otherFileKey_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Duplicate( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - otherFileRef_ = input.readInt32(); - break; - } - case 18: { - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder subBuilder = null; - if (((bitField0_ & 0x00000002) == 0x00000002)) { - subBuilder = range_.toBuilder(); - } - range_ = input.readMessage(org.sonar.batch.protocol.output.BatchReport.TextRange.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(range_); - range_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000002; - break; - } - case 26: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000004; - otherFileKey_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplicate_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplicate_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Duplicate.class, org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder.class); - } - - private int bitField0_; - public static final int OTHER_FILE_REF_FIELD_NUMBER = 1; - private int otherFileRef_; - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - public boolean hasOtherFileRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - public int getOtherFileRef() { - return otherFileRef_; - } - - public static final int RANGE_FIELD_NUMBER = 2; - private org.sonar.batch.protocol.output.BatchReport.TextRange range_; - /** - * <code>optional .TextRange range = 2;</code> - */ - public boolean hasRange() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getRange() { - return range_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getRangeOrBuilder() { - return range_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } - - public static final int OTHER_FILE_KEY_FIELD_NUMBER = 3; - private volatile java.lang.Object otherFileKey_; - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public boolean hasOtherFileKey() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public java.lang.String getOtherFileKey() { - java.lang.Object ref = otherFileKey_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - otherFileKey_ = s; - } - return s; - } - } - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public com.google.protobuf.ByteString - getOtherFileKeyBytes() { - java.lang.Object ref = otherFileKey_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - otherFileKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt32(1, otherFileRef_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeMessage(2, getRange()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeBytes(3, getOtherFileKeyBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, otherFileRef_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getRange()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(3, getOtherFileKeyBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplicate parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Duplicate prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Duplicate} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Duplicate) - org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplicate_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplicate_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Duplicate.class, org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Duplicate.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getRangeFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - otherFileRef_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - if (rangeBuilder_ == null) { - range_ = null; - } else { - rangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000002); - otherFileKey_ = ""; - bitField0_ = (bitField0_ & ~0x00000004); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplicate_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Duplicate getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Duplicate.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Duplicate build() { - org.sonar.batch.protocol.output.BatchReport.Duplicate result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Duplicate buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Duplicate result = new org.sonar.batch.protocol.output.BatchReport.Duplicate(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.otherFileRef_ = otherFileRef_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - if (rangeBuilder_ == null) { - result.range_ = range_; - } else { - result.range_ = rangeBuilder_.build(); - } - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.otherFileKey_ = otherFileKey_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Duplicate) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Duplicate)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Duplicate other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Duplicate.getDefaultInstance()) return this; - if (other.hasOtherFileRef()) { - setOtherFileRef(other.getOtherFileRef()); - } - if (other.hasRange()) { - mergeRange(other.getRange()); - } - if (other.hasOtherFileKey()) { - bitField0_ |= 0x00000004; - otherFileKey_ = other.otherFileKey_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Duplicate parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Duplicate) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int otherFileRef_ ; - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - public boolean hasOtherFileRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - public int getOtherFileRef() { - return otherFileRef_; - } - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - public Builder setOtherFileRef(int value) { - bitField0_ |= 0x00000001; - otherFileRef_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 other_file_ref = 1;</code> - * - * <pre> - * Will be null when duplicate is in the same file - * </pre> - */ - public Builder clearOtherFileRef() { - bitField0_ = (bitField0_ & ~0x00000001); - otherFileRef_ = 0; - onChanged(); - return this; - } - - private org.sonar.batch.protocol.output.BatchReport.TextRange range_ = null; - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> rangeBuilder_; - /** - * <code>optional .TextRange range = 2;</code> - */ - public boolean hasRange() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getRange() { - if (rangeBuilder_ == null) { - return range_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } else { - return rangeBuilder_.getMessage(); - } - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public Builder setRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (rangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - range_ = value; - onChanged(); - } else { - rangeBuilder_.setMessage(value); - } - bitField0_ |= 0x00000002; - return this; - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public Builder setRange( - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (rangeBuilder_ == null) { - range_ = builderForValue.build(); - onChanged(); - } else { - rangeBuilder_.setMessage(builderForValue.build()); - } - bitField0_ |= 0x00000002; - return this; - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public Builder mergeRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (rangeBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002) && - range_ != null && - range_ != org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()) { - range_ = - org.sonar.batch.protocol.output.BatchReport.TextRange.newBuilder(range_).mergeFrom(value).buildPartial(); - } else { - range_ = value; - } - onChanged(); - } else { - rangeBuilder_.mergeFrom(value); - } - bitField0_ |= 0x00000002; - return this; - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public Builder clearRange() { - if (rangeBuilder_ == null) { - range_ = null; - onChanged(); - } else { - rangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder getRangeBuilder() { - bitField0_ |= 0x00000002; - onChanged(); - return getRangeFieldBuilder().getBuilder(); - } - /** - * <code>optional .TextRange range = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getRangeOrBuilder() { - if (rangeBuilder_ != null) { - return rangeBuilder_.getMessageOrBuilder(); - } else { - return range_ == null ? - org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } - } - /** - * <code>optional .TextRange range = 2;</code> - */ - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getRangeFieldBuilder() { - if (rangeBuilder_ == null) { - rangeBuilder_ = new com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder>( - getRange(), - getParentForChildren(), - isClean()); - range_ = null; - } - return rangeBuilder_; - } - - private java.lang.Object otherFileKey_ = ""; - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public boolean hasOtherFileKey() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public java.lang.String getOtherFileKey() { - java.lang.Object ref = otherFileKey_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - otherFileKey_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public com.google.protobuf.ByteString - getOtherFileKeyBytes() { - java.lang.Object ref = otherFileKey_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - otherFileKey_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public Builder setOtherFileKey( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - otherFileKey_ = value; - onChanged(); - return this; - } - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public Builder clearOtherFileKey() { - bitField0_ = (bitField0_ & ~0x00000004); - otherFileKey_ = getDefaultInstance().getOtherFileKey(); - onChanged(); - return this; - } - /** - * <code>optional string other_file_key = 3;</code> - * - * <pre> - * temporary field during development of computation stack for cross project duplications - * </pre> - */ - public Builder setOtherFileKeyBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - otherFileKey_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Duplicate) - } - - // @@protoc_insertion_point(class_scope:Duplicate) - private static final org.sonar.batch.protocol.output.BatchReport.Duplicate DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Duplicate(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Duplicate getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Duplicate> PARSER = - new com.google.protobuf.AbstractParser<Duplicate>() { - public Duplicate parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Duplicate(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Duplicate> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Duplicate getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface DuplicationOrBuilder extends - // @@protoc_insertion_point(interface_extends:Duplication) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - boolean hasOriginPosition(); - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - org.sonar.batch.protocol.output.BatchReport.TextRange getOriginPosition(); - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getOriginPositionOrBuilder(); - - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.Duplicate> - getDuplicateList(); - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.Duplicate getDuplicate(int index); - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - int getDuplicateCount(); - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder> - getDuplicateOrBuilderList(); - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder getDuplicateOrBuilder( - int index); - } - /** - * Protobuf type {@code Duplication} - */ - public static final class Duplication extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Duplication) - DuplicationOrBuilder { - // Use Duplication.newBuilder() to construct. - private Duplication(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Duplication() { - duplicate_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Duplication( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder subBuilder = null; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - subBuilder = originPosition_.toBuilder(); - } - originPosition_ = input.readMessage(org.sonar.batch.protocol.output.BatchReport.TextRange.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originPosition_); - originPosition_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000001; - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - duplicate_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.Duplicate>(); - mutable_bitField0_ |= 0x00000002; - } - duplicate_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.Duplicate.PARSER, extensionRegistry)); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - duplicate_ = java.util.Collections.unmodifiableList(duplicate_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplication_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplication_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Duplication.class, org.sonar.batch.protocol.output.BatchReport.Duplication.Builder.class); - } - - private int bitField0_; - public static final int ORIGIN_POSITION_FIELD_NUMBER = 1; - private org.sonar.batch.protocol.output.BatchReport.TextRange originPosition_; - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public boolean hasOriginPosition() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getOriginPosition() { - return originPosition_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : originPosition_; - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getOriginPositionOrBuilder() { - return originPosition_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : originPosition_; - } - - public static final int DUPLICATE_FIELD_NUMBER = 2; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.Duplicate> duplicate_; - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Duplicate> getDuplicateList() { - return duplicate_; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder> - getDuplicateOrBuilderList() { - return duplicate_; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public int getDuplicateCount() { - return duplicate_.size(); - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Duplicate getDuplicate(int index) { - return duplicate_.get(index); - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder getDuplicateOrBuilder( - int index) { - return duplicate_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeMessage(1, getOriginPosition()); - } - for (int i = 0; i < duplicate_.size(); i++) { - output.writeMessage(2, duplicate_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getOriginPosition()); - } - for (int i = 0; i < duplicate_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, duplicate_.get(i)); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Duplication parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Duplication prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Duplication} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Duplication) - org.sonar.batch.protocol.output.BatchReport.DuplicationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplication_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplication_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Duplication.class, org.sonar.batch.protocol.output.BatchReport.Duplication.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Duplication.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getOriginPositionFieldBuilder(); - getDuplicateFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (originPositionBuilder_ == null) { - originPosition_ = null; - } else { - originPositionBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - if (duplicateBuilder_ == null) { - duplicate_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - duplicateBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Duplication_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Duplication getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Duplication.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Duplication build() { - org.sonar.batch.protocol.output.BatchReport.Duplication result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Duplication buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Duplication result = new org.sonar.batch.protocol.output.BatchReport.Duplication(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - if (originPositionBuilder_ == null) { - result.originPosition_ = originPosition_; - } else { - result.originPosition_ = originPositionBuilder_.build(); - } - if (duplicateBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - duplicate_ = java.util.Collections.unmodifiableList(duplicate_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.duplicate_ = duplicate_; - } else { - result.duplicate_ = duplicateBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Duplication) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Duplication)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Duplication other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Duplication.getDefaultInstance()) return this; - if (other.hasOriginPosition()) { - mergeOriginPosition(other.getOriginPosition()); - } - if (duplicateBuilder_ == null) { - if (!other.duplicate_.isEmpty()) { - if (duplicate_.isEmpty()) { - duplicate_ = other.duplicate_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureDuplicateIsMutable(); - duplicate_.addAll(other.duplicate_); - } - onChanged(); - } - } else { - if (!other.duplicate_.isEmpty()) { - if (duplicateBuilder_.isEmpty()) { - duplicateBuilder_.dispose(); - duplicateBuilder_ = null; - duplicate_ = other.duplicate_; - bitField0_ = (bitField0_ & ~0x00000002); - duplicateBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getDuplicateFieldBuilder() : null; - } else { - duplicateBuilder_.addAllMessages(other.duplicate_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Duplication parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Duplication) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private org.sonar.batch.protocol.output.BatchReport.TextRange originPosition_ = null; - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> originPositionBuilder_; - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public boolean hasOriginPosition() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getOriginPosition() { - if (originPositionBuilder_ == null) { - return originPosition_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : originPosition_; - } else { - return originPositionBuilder_.getMessage(); - } - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public Builder setOriginPosition(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (originPositionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - originPosition_ = value; - onChanged(); - } else { - originPositionBuilder_.setMessage(value); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public Builder setOriginPosition( - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (originPositionBuilder_ == null) { - originPosition_ = builderForValue.build(); - onChanged(); - } else { - originPositionBuilder_.setMessage(builderForValue.build()); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public Builder mergeOriginPosition(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (originPositionBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001) && - originPosition_ != null && - originPosition_ != org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()) { - originPosition_ = - org.sonar.batch.protocol.output.BatchReport.TextRange.newBuilder(originPosition_).mergeFrom(value).buildPartial(); - } else { - originPosition_ = value; - } - onChanged(); - } else { - originPositionBuilder_.mergeFrom(value); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public Builder clearOriginPosition() { - if (originPositionBuilder_ == null) { - originPosition_ = null; - onChanged(); - } else { - originPositionBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder getOriginPositionBuilder() { - bitField0_ |= 0x00000001; - onChanged(); - return getOriginPositionFieldBuilder().getBuilder(); - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getOriginPositionOrBuilder() { - if (originPositionBuilder_ != null) { - return originPositionBuilder_.getMessageOrBuilder(); - } else { - return originPosition_ == null ? - org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : originPosition_; - } - } - /** - * <code>optional .TextRange origin_position = 1;</code> - * - * <pre> - * Origin position in current file - * </pre> - */ - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getOriginPositionFieldBuilder() { - if (originPositionBuilder_ == null) { - originPositionBuilder_ = new com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder>( - getOriginPosition(), - getParentForChildren(), - isClean()); - originPosition_ = null; - } - return originPositionBuilder_; - } - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.Duplicate> duplicate_ = - java.util.Collections.emptyList(); - private void ensureDuplicateIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - duplicate_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.Duplicate>(duplicate_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Duplicate, org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder, org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder> duplicateBuilder_; - - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Duplicate> getDuplicateList() { - if (duplicateBuilder_ == null) { - return java.util.Collections.unmodifiableList(duplicate_); - } else { - return duplicateBuilder_.getMessageList(); - } - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public int getDuplicateCount() { - if (duplicateBuilder_ == null) { - return duplicate_.size(); - } else { - return duplicateBuilder_.getCount(); - } - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Duplicate getDuplicate(int index) { - if (duplicateBuilder_ == null) { - return duplicate_.get(index); - } else { - return duplicateBuilder_.getMessage(index); - } - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder setDuplicate( - int index, org.sonar.batch.protocol.output.BatchReport.Duplicate value) { - if (duplicateBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDuplicateIsMutable(); - duplicate_.set(index, value); - onChanged(); - } else { - duplicateBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder setDuplicate( - int index, org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder builderForValue) { - if (duplicateBuilder_ == null) { - ensureDuplicateIsMutable(); - duplicate_.set(index, builderForValue.build()); - onChanged(); - } else { - duplicateBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder addDuplicate(org.sonar.batch.protocol.output.BatchReport.Duplicate value) { - if (duplicateBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDuplicateIsMutable(); - duplicate_.add(value); - onChanged(); - } else { - duplicateBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder addDuplicate( - int index, org.sonar.batch.protocol.output.BatchReport.Duplicate value) { - if (duplicateBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureDuplicateIsMutable(); - duplicate_.add(index, value); - onChanged(); - } else { - duplicateBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder addDuplicate( - org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder builderForValue) { - if (duplicateBuilder_ == null) { - ensureDuplicateIsMutable(); - duplicate_.add(builderForValue.build()); - onChanged(); - } else { - duplicateBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder addDuplicate( - int index, org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder builderForValue) { - if (duplicateBuilder_ == null) { - ensureDuplicateIsMutable(); - duplicate_.add(index, builderForValue.build()); - onChanged(); - } else { - duplicateBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder addAllDuplicate( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.Duplicate> values) { - if (duplicateBuilder_ == null) { - ensureDuplicateIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, duplicate_); - onChanged(); - } else { - duplicateBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder clearDuplicate() { - if (duplicateBuilder_ == null) { - duplicate_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - duplicateBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public Builder removeDuplicate(int index) { - if (duplicateBuilder_ == null) { - ensureDuplicateIsMutable(); - duplicate_.remove(index); - onChanged(); - } else { - duplicateBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder getDuplicateBuilder( - int index) { - return getDuplicateFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder getDuplicateOrBuilder( - int index) { - if (duplicateBuilder_ == null) { - return duplicate_.get(index); } else { - return duplicateBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder> - getDuplicateOrBuilderList() { - if (duplicateBuilder_ != null) { - return duplicateBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(duplicate_); - } - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder addDuplicateBuilder() { - return getDuplicateFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.Duplicate.getDefaultInstance()); - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder addDuplicateBuilder( - int index) { - return getDuplicateFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.Duplicate.getDefaultInstance()); - } - /** - * <code>repeated .Duplicate duplicate = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder> - getDuplicateBuilderList() { - return getDuplicateFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Duplicate, org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder, org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder> - getDuplicateFieldBuilder() { - if (duplicateBuilder_ == null) { - duplicateBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.Duplicate, org.sonar.batch.protocol.output.BatchReport.Duplicate.Builder, org.sonar.batch.protocol.output.BatchReport.DuplicateOrBuilder>( - duplicate_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - duplicate_ = null; - } - return duplicateBuilder_; - } - - // @@protoc_insertion_point(builder_scope:Duplication) - } - - // @@protoc_insertion_point(class_scope:Duplication) - private static final org.sonar.batch.protocol.output.BatchReport.Duplication DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Duplication(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Duplication getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Duplication> PARSER = - new com.google.protobuf.AbstractParser<Duplication>() { - public Duplication parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Duplication(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Duplication> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Duplication getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface TextRangeOrBuilder extends - // @@protoc_insertion_point(interface_extends:TextRange) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - boolean hasStartLine(); - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - int getStartLine(); - - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - boolean hasEndLine(); - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - int getEndLine(); - - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - boolean hasStartOffset(); - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - int getStartOffset(); - - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - boolean hasEndOffset(); - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - int getEndOffset(); - } - /** - * Protobuf type {@code TextRange} - * - * <pre> - * Lines start at 1 and line offsets start at 0 - * </pre> - */ - public static final class TextRange extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:TextRange) - TextRangeOrBuilder { - // Use TextRange.newBuilder() to construct. - private TextRange(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private TextRange() { - startLine_ = 0; - endLine_ = 0; - startOffset_ = 0; - endOffset_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private TextRange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - startLine_ = input.readInt32(); - break; - } - case 16: { - bitField0_ |= 0x00000002; - endLine_ = input.readInt32(); - break; - } - case 24: { - bitField0_ |= 0x00000004; - startOffset_ = input.readInt32(); - break; - } - case 32: { - bitField0_ |= 0x00000008; - endOffset_ = input.readInt32(); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_TextRange_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_TextRange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.TextRange.class, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder.class); - } - - private int bitField0_; - public static final int START_LINE_FIELD_NUMBER = 1; - private int startLine_; - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - public boolean hasStartLine() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - public int getStartLine() { - return startLine_; - } - - public static final int END_LINE_FIELD_NUMBER = 2; - private int endLine_; - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - public boolean hasEndLine() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - public int getEndLine() { - return endLine_; - } - - public static final int START_OFFSET_FIELD_NUMBER = 3; - private int startOffset_; - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - public boolean hasStartOffset() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - public int getStartOffset() { - return startOffset_; - } - - public static final int END_OFFSET_FIELD_NUMBER = 4; - private int endOffset_; - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - public boolean hasEndOffset() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - public int getEndOffset() { - return endOffset_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt32(1, startLine_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeInt32(2, endLine_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeInt32(3, startOffset_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeInt32(4, endOffset_); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, startLine_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, endLine_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(3, startOffset_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(4, endOffset_); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.TextRange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.TextRange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code TextRange} - * - * <pre> - * Lines start at 1 and line offsets start at 0 - * </pre> - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:TextRange) - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_TextRange_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_TextRange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.TextRange.class, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.TextRange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - startLine_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - endLine_ = 0; - bitField0_ = (bitField0_ & ~0x00000002); - startOffset_ = 0; - bitField0_ = (bitField0_ & ~0x00000004); - endOffset_ = 0; - bitField0_ = (bitField0_ & ~0x00000008); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_TextRange_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.TextRange getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.TextRange build() { - org.sonar.batch.protocol.output.BatchReport.TextRange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.TextRange buildPartial() { - org.sonar.batch.protocol.output.BatchReport.TextRange result = new org.sonar.batch.protocol.output.BatchReport.TextRange(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.startLine_ = startLine_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.endLine_ = endLine_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.startOffset_ = startOffset_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.endOffset_ = endOffset_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.TextRange) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.TextRange)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.TextRange other) { - if (other == org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()) return this; - if (other.hasStartLine()) { - setStartLine(other.getStartLine()); - } - if (other.hasEndLine()) { - setEndLine(other.getEndLine()); - } - if (other.hasStartOffset()) { - setStartOffset(other.getStartOffset()); - } - if (other.hasEndOffset()) { - setEndOffset(other.getEndOffset()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.TextRange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.TextRange) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int startLine_ ; - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - public boolean hasStartLine() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - public int getStartLine() { - return startLine_; - } - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - public Builder setStartLine(int value) { - bitField0_ |= 0x00000001; - startLine_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 start_line = 1;</code> - * - * <pre> - * Should never be null - * </pre> - */ - public Builder clearStartLine() { - bitField0_ = (bitField0_ & ~0x00000001); - startLine_ = 0; - onChanged(); - return this; - } - - private int endLine_ ; - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - public boolean hasEndLine() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - public int getEndLine() { - return endLine_; - } - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - public Builder setEndLine(int value) { - bitField0_ |= 0x00000002; - endLine_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 end_line = 2;</code> - * - * <pre> - * End line (inclusive). Null means it is same as start line - * </pre> - */ - public Builder clearEndLine() { - bitField0_ = (bitField0_ & ~0x00000002); - endLine_ = 0; - onChanged(); - return this; - } - - private int startOffset_ ; - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - public boolean hasStartOffset() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - public int getStartOffset() { - return startOffset_; - } - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - public Builder setStartOffset(int value) { - bitField0_ |= 0x00000004; - startOffset_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 start_offset = 3;</code> - * - * <pre> - * If null it means range starts at the first offset of start line - * </pre> - */ - public Builder clearStartOffset() { - bitField0_ = (bitField0_ & ~0x00000004); - startOffset_ = 0; - onChanged(); - return this; - } - - private int endOffset_ ; - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - public boolean hasEndOffset() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - public int getEndOffset() { - return endOffset_; - } - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - public Builder setEndOffset(int value) { - bitField0_ |= 0x00000008; - endOffset_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 end_offset = 4;</code> - * - * <pre> - * If null it means range ends at the last offset of end line - * </pre> - */ - public Builder clearEndOffset() { - bitField0_ = (bitField0_ & ~0x00000008); - endOffset_ = 0; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:TextRange) - } - - // @@protoc_insertion_point(class_scope:TextRange) - private static final org.sonar.batch.protocol.output.BatchReport.TextRange DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.TextRange(); - } - - public static org.sonar.batch.protocol.output.BatchReport.TextRange getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<TextRange> PARSER = - new com.google.protobuf.AbstractParser<TextRange>() { - public TextRange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new TextRange(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<TextRange> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.TextRange getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface SymbolOrBuilder extends - // @@protoc_insertion_point(interface_extends:Symbol) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional .TextRange declaration = 1;</code> - */ - boolean hasDeclaration(); - /** - * <code>optional .TextRange declaration = 1;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRange getDeclaration(); - /** - * <code>optional .TextRange declaration = 1;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getDeclarationOrBuilder(); - - /** - * <code>repeated .TextRange reference = 2;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.TextRange> - getReferenceList(); - /** - * <code>repeated .TextRange reference = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRange getReference(int index); - /** - * <code>repeated .TextRange reference = 2;</code> - */ - int getReferenceCount(); - /** - * <code>repeated .TextRange reference = 2;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getReferenceOrBuilderList(); - /** - * <code>repeated .TextRange reference = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getReferenceOrBuilder( - int index); - } - /** - * Protobuf type {@code Symbol} - */ - public static final class Symbol extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Symbol) - SymbolOrBuilder { - // Use Symbol.newBuilder() to construct. - private Symbol(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Symbol() { - reference_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Symbol( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder subBuilder = null; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - subBuilder = declaration_.toBuilder(); - } - declaration_ = input.readMessage(org.sonar.batch.protocol.output.BatchReport.TextRange.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(declaration_); - declaration_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000001; - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - reference_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.TextRange>(); - mutable_bitField0_ |= 0x00000002; - } - reference_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.TextRange.PARSER, extensionRegistry)); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - reference_ = java.util.Collections.unmodifiableList(reference_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Symbol_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Symbol_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Symbol.class, org.sonar.batch.protocol.output.BatchReport.Symbol.Builder.class); - } - - private int bitField0_; - public static final int DECLARATION_FIELD_NUMBER = 1; - private org.sonar.batch.protocol.output.BatchReport.TextRange declaration_; - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public boolean hasDeclaration() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getDeclaration() { - return declaration_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : declaration_; - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getDeclarationOrBuilder() { - return declaration_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : declaration_; - } - - public static final int REFERENCE_FIELD_NUMBER = 2; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.TextRange> reference_; - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.TextRange> getReferenceList() { - return reference_; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getReferenceOrBuilderList() { - return reference_; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public int getReferenceCount() { - return reference_.size(); - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getReference(int index) { - return reference_.get(index); - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getReferenceOrBuilder( - int index) { - return reference_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeMessage(1, getDeclaration()); - } - for (int i = 0; i < reference_.size(); i++) { - output.writeMessage(2, reference_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getDeclaration()); - } - for (int i = 0; i < reference_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, reference_.get(i)); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Symbol parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Symbol prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Symbol} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Symbol) - org.sonar.batch.protocol.output.BatchReport.SymbolOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Symbol_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Symbol_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Symbol.class, org.sonar.batch.protocol.output.BatchReport.Symbol.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Symbol.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getDeclarationFieldBuilder(); - getReferenceFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (declarationBuilder_ == null) { - declaration_ = null; - } else { - declarationBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - if (referenceBuilder_ == null) { - reference_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - referenceBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Symbol_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Symbol getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Symbol.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Symbol build() { - org.sonar.batch.protocol.output.BatchReport.Symbol result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Symbol buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Symbol result = new org.sonar.batch.protocol.output.BatchReport.Symbol(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - if (declarationBuilder_ == null) { - result.declaration_ = declaration_; - } else { - result.declaration_ = declarationBuilder_.build(); - } - if (referenceBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - reference_ = java.util.Collections.unmodifiableList(reference_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.reference_ = reference_; - } else { - result.reference_ = referenceBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Symbol) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Symbol)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Symbol other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Symbol.getDefaultInstance()) return this; - if (other.hasDeclaration()) { - mergeDeclaration(other.getDeclaration()); - } - if (referenceBuilder_ == null) { - if (!other.reference_.isEmpty()) { - if (reference_.isEmpty()) { - reference_ = other.reference_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureReferenceIsMutable(); - reference_.addAll(other.reference_); - } - onChanged(); - } - } else { - if (!other.reference_.isEmpty()) { - if (referenceBuilder_.isEmpty()) { - referenceBuilder_.dispose(); - referenceBuilder_ = null; - reference_ = other.reference_; - bitField0_ = (bitField0_ & ~0x00000002); - referenceBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getReferenceFieldBuilder() : null; - } else { - referenceBuilder_.addAllMessages(other.reference_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Symbol parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Symbol) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private org.sonar.batch.protocol.output.BatchReport.TextRange declaration_ = null; - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> declarationBuilder_; - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public boolean hasDeclaration() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getDeclaration() { - if (declarationBuilder_ == null) { - return declaration_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : declaration_; - } else { - return declarationBuilder_.getMessage(); - } - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public Builder setDeclaration(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (declarationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - declaration_ = value; - onChanged(); - } else { - declarationBuilder_.setMessage(value); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public Builder setDeclaration( - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (declarationBuilder_ == null) { - declaration_ = builderForValue.build(); - onChanged(); - } else { - declarationBuilder_.setMessage(builderForValue.build()); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public Builder mergeDeclaration(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (declarationBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001) && - declaration_ != null && - declaration_ != org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()) { - declaration_ = - org.sonar.batch.protocol.output.BatchReport.TextRange.newBuilder(declaration_).mergeFrom(value).buildPartial(); - } else { - declaration_ = value; - } - onChanged(); - } else { - declarationBuilder_.mergeFrom(value); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public Builder clearDeclaration() { - if (declarationBuilder_ == null) { - declaration_ = null; - onChanged(); - } else { - declarationBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder getDeclarationBuilder() { - bitField0_ |= 0x00000001; - onChanged(); - return getDeclarationFieldBuilder().getBuilder(); - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getDeclarationOrBuilder() { - if (declarationBuilder_ != null) { - return declarationBuilder_.getMessageOrBuilder(); - } else { - return declaration_ == null ? - org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : declaration_; - } - } - /** - * <code>optional .TextRange declaration = 1;</code> - */ - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getDeclarationFieldBuilder() { - if (declarationBuilder_ == null) { - declarationBuilder_ = new com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder>( - getDeclaration(), - getParentForChildren(), - isClean()); - declaration_ = null; - } - return declarationBuilder_; - } - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.TextRange> reference_ = - java.util.Collections.emptyList(); - private void ensureReferenceIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - reference_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.TextRange>(reference_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> referenceBuilder_; - - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.TextRange> getReferenceList() { - if (referenceBuilder_ == null) { - return java.util.Collections.unmodifiableList(reference_); - } else { - return referenceBuilder_.getMessageList(); - } - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public int getReferenceCount() { - if (referenceBuilder_ == null) { - return reference_.size(); - } else { - return referenceBuilder_.getCount(); - } - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getReference(int index) { - if (referenceBuilder_ == null) { - return reference_.get(index); - } else { - return referenceBuilder_.getMessage(index); - } - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder setReference( - int index, org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (referenceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferenceIsMutable(); - reference_.set(index, value); - onChanged(); - } else { - referenceBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder setReference( - int index, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (referenceBuilder_ == null) { - ensureReferenceIsMutable(); - reference_.set(index, builderForValue.build()); - onChanged(); - } else { - referenceBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder addReference(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (referenceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferenceIsMutable(); - reference_.add(value); - onChanged(); - } else { - referenceBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder addReference( - int index, org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (referenceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferenceIsMutable(); - reference_.add(index, value); - onChanged(); - } else { - referenceBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder addReference( - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (referenceBuilder_ == null) { - ensureReferenceIsMutable(); - reference_.add(builderForValue.build()); - onChanged(); - } else { - referenceBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder addReference( - int index, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (referenceBuilder_ == null) { - ensureReferenceIsMutable(); - reference_.add(index, builderForValue.build()); - onChanged(); - } else { - referenceBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder addAllReference( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.TextRange> values) { - if (referenceBuilder_ == null) { - ensureReferenceIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, reference_); - onChanged(); - } else { - referenceBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder clearReference() { - if (referenceBuilder_ == null) { - reference_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - referenceBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public Builder removeReference(int index) { - if (referenceBuilder_ == null) { - ensureReferenceIsMutable(); - reference_.remove(index); - onChanged(); - } else { - referenceBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder getReferenceBuilder( - int index) { - return getReferenceFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getReferenceOrBuilder( - int index) { - if (referenceBuilder_ == null) { - return reference_.get(index); } else { - return referenceBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getReferenceOrBuilderList() { - if (referenceBuilder_ != null) { - return referenceBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(reference_); - } - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder addReferenceBuilder() { - return getReferenceFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()); - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder addReferenceBuilder( - int index) { - return getReferenceFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()); - } - /** - * <code>repeated .TextRange reference = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.TextRange.Builder> - getReferenceBuilderList() { - return getReferenceFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getReferenceFieldBuilder() { - if (referenceBuilder_ == null) { - referenceBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder>( - reference_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - reference_ = null; - } - return referenceBuilder_; - } - - // @@protoc_insertion_point(builder_scope:Symbol) - } - - // @@protoc_insertion_point(class_scope:Symbol) - private static final org.sonar.batch.protocol.output.BatchReport.Symbol DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Symbol(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Symbol getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Symbol> PARSER = - new com.google.protobuf.AbstractParser<Symbol>() { - public Symbol parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Symbol(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Symbol> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Symbol getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface CoverageOrBuilder extends - // @@protoc_insertion_point(interface_extends:Coverage) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int32 line = 1;</code> - */ - boolean hasLine(); - /** - * <code>optional int32 line = 1;</code> - */ - int getLine(); - - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - boolean hasConditions(); - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - int getConditions(); - - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - boolean hasUtHits(); - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - boolean getUtHits(); - - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - boolean hasItHits(); - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - boolean getItHits(); - - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - boolean hasUtCoveredConditions(); - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - int getUtCoveredConditions(); - - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - boolean hasItCoveredConditions(); - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - int getItCoveredConditions(); - - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - boolean hasOverallCoveredConditions(); - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - int getOverallCoveredConditions(); - } - /** - * Protobuf type {@code Coverage} - * - * <pre> - * Only FILE component has coverage information, and only executable lines should contains this information. - * TODO rename it LineCoverage ? - * </pre> - */ - public static final class Coverage extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Coverage) - CoverageOrBuilder { - // Use Coverage.newBuilder() to construct. - private Coverage(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Coverage() { - line_ = 0; - conditions_ = 0; - utHits_ = false; - itHits_ = false; - utCoveredConditions_ = 0; - itCoveredConditions_ = 0; - overallCoveredConditions_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Coverage( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - line_ = input.readInt32(); - break; - } - case 16: { - bitField0_ |= 0x00000002; - conditions_ = input.readInt32(); - break; - } - case 24: { - bitField0_ |= 0x00000004; - utHits_ = input.readBool(); - break; - } - case 32: { - bitField0_ |= 0x00000008; - itHits_ = input.readBool(); - break; - } - case 40: { - bitField0_ |= 0x00000010; - utCoveredConditions_ = input.readInt32(); - break; - } - case 48: { - bitField0_ |= 0x00000020; - itCoveredConditions_ = input.readInt32(); - break; - } - case 56: { - bitField0_ |= 0x00000040; - overallCoveredConditions_ = input.readInt32(); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Coverage_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Coverage_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Coverage.class, org.sonar.batch.protocol.output.BatchReport.Coverage.Builder.class); - } - - private int bitField0_; - public static final int LINE_FIELD_NUMBER = 1; - private int line_; - /** - * <code>optional int32 line = 1;</code> - */ - public boolean hasLine() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 line = 1;</code> - */ - public int getLine() { - return line_; - } - - public static final int CONDITIONS_FIELD_NUMBER = 2; - private int conditions_; - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - public boolean hasConditions() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - public int getConditions() { - return conditions_; - } - - public static final int UT_HITS_FIELD_NUMBER = 3; - private boolean utHits_; - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean hasUtHits() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean getUtHits() { - return utHits_; - } - - public static final int IT_HITS_FIELD_NUMBER = 4; - private boolean itHits_; - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean hasItHits() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean getItHits() { - return itHits_; - } - - public static final int UT_COVERED_CONDITIONS_FIELD_NUMBER = 5; - private int utCoveredConditions_; - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - public boolean hasUtCoveredConditions() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - public int getUtCoveredConditions() { - return utCoveredConditions_; - } - - public static final int IT_COVERED_CONDITIONS_FIELD_NUMBER = 6; - private int itCoveredConditions_; - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - public boolean hasItCoveredConditions() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - public int getItCoveredConditions() { - return itCoveredConditions_; - } - - public static final int OVERALL_COVERED_CONDITIONS_FIELD_NUMBER = 7; - private int overallCoveredConditions_; - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - public boolean hasOverallCoveredConditions() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - public int getOverallCoveredConditions() { - return overallCoveredConditions_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt32(1, line_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeInt32(2, conditions_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeBool(3, utHits_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeBool(4, itHits_); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - output.writeInt32(5, utCoveredConditions_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - output.writeInt32(6, itCoveredConditions_); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - output.writeInt32(7, overallCoveredConditions_); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, line_); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, conditions_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(3, utHits_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(4, itHits_); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(5, utCoveredConditions_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(6, itCoveredConditions_); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(7, overallCoveredConditions_); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Coverage parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Coverage prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Coverage} - * - * <pre> - * Only FILE component has coverage information, and only executable lines should contains this information. - * TODO rename it LineCoverage ? - * </pre> - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Coverage) - org.sonar.batch.protocol.output.BatchReport.CoverageOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Coverage_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Coverage_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Coverage.class, org.sonar.batch.protocol.output.BatchReport.Coverage.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Coverage.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - line_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - conditions_ = 0; - bitField0_ = (bitField0_ & ~0x00000002); - utHits_ = false; - bitField0_ = (bitField0_ & ~0x00000004); - itHits_ = false; - bitField0_ = (bitField0_ & ~0x00000008); - utCoveredConditions_ = 0; - bitField0_ = (bitField0_ & ~0x00000010); - itCoveredConditions_ = 0; - bitField0_ = (bitField0_ & ~0x00000020); - overallCoveredConditions_ = 0; - bitField0_ = (bitField0_ & ~0x00000040); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Coverage_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Coverage getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Coverage.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Coverage build() { - org.sonar.batch.protocol.output.BatchReport.Coverage result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Coverage buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Coverage result = new org.sonar.batch.protocol.output.BatchReport.Coverage(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.line_ = line_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.conditions_ = conditions_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.utHits_ = utHits_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.itHits_ = itHits_; - if (((from_bitField0_ & 0x00000010) == 0x00000010)) { - to_bitField0_ |= 0x00000010; - } - result.utCoveredConditions_ = utCoveredConditions_; - if (((from_bitField0_ & 0x00000020) == 0x00000020)) { - to_bitField0_ |= 0x00000020; - } - result.itCoveredConditions_ = itCoveredConditions_; - if (((from_bitField0_ & 0x00000040) == 0x00000040)) { - to_bitField0_ |= 0x00000040; - } - result.overallCoveredConditions_ = overallCoveredConditions_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Coverage) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Coverage)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Coverage other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Coverage.getDefaultInstance()) return this; - if (other.hasLine()) { - setLine(other.getLine()); - } - if (other.hasConditions()) { - setConditions(other.getConditions()); - } - if (other.hasUtHits()) { - setUtHits(other.getUtHits()); - } - if (other.hasItHits()) { - setItHits(other.getItHits()); - } - if (other.hasUtCoveredConditions()) { - setUtCoveredConditions(other.getUtCoveredConditions()); - } - if (other.hasItCoveredConditions()) { - setItCoveredConditions(other.getItCoveredConditions()); - } - if (other.hasOverallCoveredConditions()) { - setOverallCoveredConditions(other.getOverallCoveredConditions()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Coverage parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Coverage) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int line_ ; - /** - * <code>optional int32 line = 1;</code> - */ - public boolean hasLine() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 line = 1;</code> - */ - public int getLine() { - return line_; - } - /** - * <code>optional int32 line = 1;</code> - */ - public Builder setLine(int value) { - bitField0_ |= 0x00000001; - line_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 line = 1;</code> - */ - public Builder clearLine() { - bitField0_ = (bitField0_ & ~0x00000001); - line_ = 0; - onChanged(); - return this; - } - - private int conditions_ ; - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - public boolean hasConditions() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - public int getConditions() { - return conditions_; - } - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - public Builder setConditions(int value) { - bitField0_ |= 0x00000002; - conditions_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 conditions = 2;</code> - * - * <pre> - * Number of conditions to cover (if set, the value must be greater than 0) - * </pre> - */ - public Builder clearConditions() { - bitField0_ = (bitField0_ & ~0x00000002); - conditions_ = 0; - onChanged(); - return this; - } - - private boolean utHits_ ; - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean hasUtHits() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean getUtHits() { - return utHits_; - } - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public Builder setUtHits(boolean value) { - bitField0_ |= 0x00000004; - utHits_ = value; - onChanged(); - return this; - } - /** - * <code>optional bool ut_hits = 3;</code> - * - * <pre> - * Is the line has been touched by a unit test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public Builder clearUtHits() { - bitField0_ = (bitField0_ & ~0x00000004); - utHits_ = false; - onChanged(); - return this; - } - - private boolean itHits_ ; - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean hasItHits() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public boolean getItHits() { - return itHits_; - } - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public Builder setItHits(boolean value) { - bitField0_ |= 0x00000008; - itHits_ = value; - onChanged(); - return this; - } - /** - * <code>optional bool it_hits = 4;</code> - * - * <pre> - * Is the line has been touched by a integration test ? Returning false means that no test has touched this executable line. - * </pre> - */ - public Builder clearItHits() { - bitField0_ = (bitField0_ & ~0x00000008); - itHits_ = false; - onChanged(); - return this; - } - - private int utCoveredConditions_ ; - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - public boolean hasUtCoveredConditions() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - public int getUtCoveredConditions() { - return utCoveredConditions_; - } - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - public Builder setUtCoveredConditions(int value) { - bitField0_ |= 0x00000010; - utCoveredConditions_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 ut_covered_conditions = 5;</code> - * - * <pre> - * Number of conditions covered by unit tests - * </pre> - */ - public Builder clearUtCoveredConditions() { - bitField0_ = (bitField0_ & ~0x00000010); - utCoveredConditions_ = 0; - onChanged(); - return this; - } - - private int itCoveredConditions_ ; - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - public boolean hasItCoveredConditions() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - public int getItCoveredConditions() { - return itCoveredConditions_; - } - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - public Builder setItCoveredConditions(int value) { - bitField0_ |= 0x00000020; - itCoveredConditions_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 it_covered_conditions = 6;</code> - * - * <pre> - * Number of conditions covered by integration tests - * </pre> - */ - public Builder clearItCoveredConditions() { - bitField0_ = (bitField0_ & ~0x00000020); - itCoveredConditions_ = 0; - onChanged(); - return this; - } - - private int overallCoveredConditions_ ; - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - public boolean hasOverallCoveredConditions() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - public int getOverallCoveredConditions() { - return overallCoveredConditions_; - } - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - public Builder setOverallCoveredConditions(int value) { - bitField0_ |= 0x00000040; - overallCoveredConditions_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 overall_covered_conditions = 7;</code> - * - * <pre> - * Number of conditions covered by overall tests - * </pre> - */ - public Builder clearOverallCoveredConditions() { - bitField0_ = (bitField0_ & ~0x00000040); - overallCoveredConditions_ = 0; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Coverage) - } - - // @@protoc_insertion_point(class_scope:Coverage) - private static final org.sonar.batch.protocol.output.BatchReport.Coverage DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Coverage(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Coverage getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Coverage> PARSER = - new com.google.protobuf.AbstractParser<Coverage>() { - public Coverage parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Coverage(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Coverage> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Coverage getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface SyntaxHighlightingOrBuilder extends - // @@protoc_insertion_point(interface_extends:SyntaxHighlighting) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional .TextRange range = 1;</code> - */ - boolean hasRange(); - /** - * <code>optional .TextRange range = 1;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRange getRange(); - /** - * <code>optional .TextRange range = 1;</code> - */ - org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getRangeOrBuilder(); - - /** - * <code>optional .HighlightingType type = 2;</code> - */ - boolean hasType(); - /** - * <code>optional .HighlightingType type = 2;</code> - */ - org.sonar.batch.protocol.Constants.HighlightingType getType(); - } - /** - * Protobuf type {@code SyntaxHighlighting} - * - * <pre> - * Must be sorted by line and start offset - * TODO rename it SyntaxHighlightingRule ? - * </pre> - */ - public static final class SyntaxHighlighting extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:SyntaxHighlighting) - SyntaxHighlightingOrBuilder { - // Use SyntaxHighlighting.newBuilder() to construct. - private SyntaxHighlighting(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private SyntaxHighlighting() { - type_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private SyntaxHighlighting( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder subBuilder = null; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - subBuilder = range_.toBuilder(); - } - range_ = input.readMessage(org.sonar.batch.protocol.output.BatchReport.TextRange.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(range_); - range_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000001; - break; - } - case 16: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.HighlightingType value = org.sonar.batch.protocol.Constants.HighlightingType.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(2, rawValue); - } else { - bitField0_ |= 0x00000002; - type_ = rawValue; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_SyntaxHighlighting_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_SyntaxHighlighting_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting.class, org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting.Builder.class); - } - - private int bitField0_; - public static final int RANGE_FIELD_NUMBER = 1; - private org.sonar.batch.protocol.output.BatchReport.TextRange range_; - /** - * <code>optional .TextRange range = 1;</code> - */ - public boolean hasRange() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getRange() { - return range_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getRangeOrBuilder() { - return range_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } - - public static final int TYPE_FIELD_NUMBER = 2; - private int type_; - /** - * <code>optional .HighlightingType type = 2;</code> - */ - public boolean hasType() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .HighlightingType type = 2;</code> - */ - public org.sonar.batch.protocol.Constants.HighlightingType getType() { - org.sonar.batch.protocol.Constants.HighlightingType result = org.sonar.batch.protocol.Constants.HighlightingType.valueOf(type_); - return result == null ? org.sonar.batch.protocol.Constants.HighlightingType.ANNOTATION : result; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeMessage(1, getRange()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeEnum(2, type_); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getRange()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(2, type_); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code SyntaxHighlighting} - * - * <pre> - * Must be sorted by line and start offset - * TODO rename it SyntaxHighlightingRule ? - * </pre> - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:SyntaxHighlighting) - org.sonar.batch.protocol.output.BatchReport.SyntaxHighlightingOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_SyntaxHighlighting_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_SyntaxHighlighting_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting.class, org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getRangeFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (rangeBuilder_ == null) { - range_ = null; - } else { - rangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - type_ = 0; - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_SyntaxHighlighting_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting build() { - org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting buildPartial() { - org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting result = new org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - if (rangeBuilder_ == null) { - result.range_ = range_; - } else { - result.range_ = rangeBuilder_.build(); - } - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.type_ = type_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting other) { - if (other == org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting.getDefaultInstance()) return this; - if (other.hasRange()) { - mergeRange(other.getRange()); - } - if (other.hasType()) { - setType(other.getType()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private org.sonar.batch.protocol.output.BatchReport.TextRange range_ = null; - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> rangeBuilder_; - /** - * <code>optional .TextRange range = 1;</code> - */ - public boolean hasRange() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange getRange() { - if (rangeBuilder_ == null) { - return range_ == null ? org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } else { - return rangeBuilder_.getMessage(); - } - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public Builder setRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (rangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - range_ = value; - onChanged(); - } else { - rangeBuilder_.setMessage(value); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public Builder setRange( - org.sonar.batch.protocol.output.BatchReport.TextRange.Builder builderForValue) { - if (rangeBuilder_ == null) { - range_ = builderForValue.build(); - onChanged(); - } else { - rangeBuilder_.setMessage(builderForValue.build()); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public Builder mergeRange(org.sonar.batch.protocol.output.BatchReport.TextRange value) { - if (rangeBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001) && - range_ != null && - range_ != org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance()) { - range_ = - org.sonar.batch.protocol.output.BatchReport.TextRange.newBuilder(range_).mergeFrom(value).buildPartial(); - } else { - range_ = value; - } - onChanged(); - } else { - rangeBuilder_.mergeFrom(value); - } - bitField0_ |= 0x00000001; - return this; - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public Builder clearRange() { - if (rangeBuilder_ == null) { - range_ = null; - onChanged(); - } else { - rangeBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRange.Builder getRangeBuilder() { - bitField0_ |= 0x00000001; - onChanged(); - return getRangeFieldBuilder().getBuilder(); - } - /** - * <code>optional .TextRange range = 1;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder getRangeOrBuilder() { - if (rangeBuilder_ != null) { - return rangeBuilder_.getMessageOrBuilder(); - } else { - return range_ == null ? - org.sonar.batch.protocol.output.BatchReport.TextRange.getDefaultInstance() : range_; - } - } - /** - * <code>optional .TextRange range = 1;</code> - */ - private com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder> - getRangeFieldBuilder() { - if (rangeBuilder_ == null) { - rangeBuilder_ = new com.google.protobuf.SingleFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.TextRange, org.sonar.batch.protocol.output.BatchReport.TextRange.Builder, org.sonar.batch.protocol.output.BatchReport.TextRangeOrBuilder>( - getRange(), - getParentForChildren(), - isClean()); - range_ = null; - } - return rangeBuilder_; - } - - private int type_ = 0; - /** - * <code>optional .HighlightingType type = 2;</code> - */ - public boolean hasType() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .HighlightingType type = 2;</code> - */ - public org.sonar.batch.protocol.Constants.HighlightingType getType() { - org.sonar.batch.protocol.Constants.HighlightingType result = org.sonar.batch.protocol.Constants.HighlightingType.valueOf(type_); - return result == null ? org.sonar.batch.protocol.Constants.HighlightingType.ANNOTATION : result; - } - /** - * <code>optional .HighlightingType type = 2;</code> - */ - public Builder setType(org.sonar.batch.protocol.Constants.HighlightingType value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - type_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .HighlightingType type = 2;</code> - */ - public Builder clearType() { - bitField0_ = (bitField0_ & ~0x00000002); - type_ = 0; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:SyntaxHighlighting) - } - - // @@protoc_insertion_point(class_scope:SyntaxHighlighting) - private static final org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting(); - } - - public static org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<SyntaxHighlighting> PARSER = - new com.google.protobuf.AbstractParser<SyntaxHighlighting>() { - public SyntaxHighlighting parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new SyntaxHighlighting(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<SyntaxHighlighting> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.SyntaxHighlighting getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface TestOrBuilder extends - // @@protoc_insertion_point(interface_extends:Test) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string name = 1;</code> - */ - boolean hasName(); - /** - * <code>optional string name = 1;</code> - */ - java.lang.String getName(); - /** - * <code>optional string name = 1;</code> - */ - com.google.protobuf.ByteString - getNameBytes(); - - /** - * <code>optional .TestStatus status = 2;</code> - */ - boolean hasStatus(); - /** - * <code>optional .TestStatus status = 2;</code> - */ - org.sonar.batch.protocol.Constants.TestStatus getStatus(); - - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - boolean hasDurationInMs(); - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - long getDurationInMs(); - - /** - * <code>optional string stacktrace = 4;</code> - */ - boolean hasStacktrace(); - /** - * <code>optional string stacktrace = 4;</code> - */ - java.lang.String getStacktrace(); - /** - * <code>optional string stacktrace = 4;</code> - */ - com.google.protobuf.ByteString - getStacktraceBytes(); - - /** - * <code>optional string msg = 5;</code> - */ - boolean hasMsg(); - /** - * <code>optional string msg = 5;</code> - */ - java.lang.String getMsg(); - /** - * <code>optional string msg = 5;</code> - */ - com.google.protobuf.ByteString - getMsgBytes(); - } - /** - * Protobuf type {@code Test} - */ - public static final class Test extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:Test) - TestOrBuilder { - // Use Test.newBuilder() to construct. - private Test(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private Test() { - name_ = ""; - status_ = 1; - durationInMs_ = 0L; - stacktrace_ = ""; - msg_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Test( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - name_ = bs; - break; - } - case 16: { - int rawValue = input.readEnum(); - org.sonar.batch.protocol.Constants.TestStatus value = org.sonar.batch.protocol.Constants.TestStatus.valueOf(rawValue); - if (value == null) { - unknownFields.mergeVarintField(2, rawValue); - } else { - bitField0_ |= 0x00000002; - status_ = rawValue; - } - break; - } - case 24: { - bitField0_ |= 0x00000004; - durationInMs_ = input.readInt64(); - break; - } - case 34: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000008; - stacktrace_ = bs; - break; - } - case 42: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000010; - msg_ = bs; - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Test_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Test_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Test.class, org.sonar.batch.protocol.output.BatchReport.Test.Builder.class); - } - - private int bitField0_; - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * <code>optional string name = 1;</code> - */ - public boolean hasName() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string name = 1;</code> - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - name_ = s; - } - return s; - } - } - /** - * <code>optional string name = 1;</code> - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int STATUS_FIELD_NUMBER = 2; - private int status_; - /** - * <code>optional .TestStatus status = 2;</code> - */ - public boolean hasStatus() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .TestStatus status = 2;</code> - */ - public org.sonar.batch.protocol.Constants.TestStatus getStatus() { - org.sonar.batch.protocol.Constants.TestStatus result = org.sonar.batch.protocol.Constants.TestStatus.valueOf(status_); - return result == null ? org.sonar.batch.protocol.Constants.TestStatus.OK : result; - } - - public static final int DURATION_IN_MS_FIELD_NUMBER = 3; - private long durationInMs_; - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - public boolean hasDurationInMs() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - public long getDurationInMs() { - return durationInMs_; - } - - public static final int STACKTRACE_FIELD_NUMBER = 4; - private volatile java.lang.Object stacktrace_; - /** - * <code>optional string stacktrace = 4;</code> - */ - public boolean hasStacktrace() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional string stacktrace = 4;</code> - */ - public java.lang.String getStacktrace() { - java.lang.Object ref = stacktrace_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - stacktrace_ = s; - } - return s; - } - } - /** - * <code>optional string stacktrace = 4;</code> - */ - public com.google.protobuf.ByteString - getStacktraceBytes() { - java.lang.Object ref = stacktrace_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - stacktrace_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int MSG_FIELD_NUMBER = 5; - private volatile java.lang.Object msg_; - /** - * <code>optional string msg = 5;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional string msg = 5;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } - } - /** - * <code>optional string msg = 5;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getNameBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeEnum(2, status_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeInt64(3, durationInMs_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeBytes(4, getStacktraceBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - output.writeBytes(5, getMsgBytes()); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getNameBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(2, status_); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(3, durationInMs_); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(4, getStacktraceBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(5, getMsgBytes()); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.Test parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.Test prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code Test} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:Test) - org.sonar.batch.protocol.output.BatchReport.TestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Test_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Test_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.Test.class, org.sonar.batch.protocol.output.BatchReport.Test.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.Test.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - name_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - status_ = 1; - bitField0_ = (bitField0_ & ~0x00000002); - durationInMs_ = 0L; - bitField0_ = (bitField0_ & ~0x00000004); - stacktrace_ = ""; - bitField0_ = (bitField0_ & ~0x00000008); - msg_ = ""; - bitField0_ = (bitField0_ & ~0x00000010); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_Test_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.Test getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.Test.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.Test build() { - org.sonar.batch.protocol.output.BatchReport.Test result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.Test buildPartial() { - org.sonar.batch.protocol.output.BatchReport.Test result = new org.sonar.batch.protocol.output.BatchReport.Test(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.name_ = name_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.status_ = status_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.durationInMs_ = durationInMs_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.stacktrace_ = stacktrace_; - if (((from_bitField0_ & 0x00000010) == 0x00000010)) { - to_bitField0_ |= 0x00000010; - } - result.msg_ = msg_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.Test) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.Test)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.Test other) { - if (other == org.sonar.batch.protocol.output.BatchReport.Test.getDefaultInstance()) return this; - if (other.hasName()) { - bitField0_ |= 0x00000001; - name_ = other.name_; - onChanged(); - } - if (other.hasStatus()) { - setStatus(other.getStatus()); - } - if (other.hasDurationInMs()) { - setDurationInMs(other.getDurationInMs()); - } - if (other.hasStacktrace()) { - bitField0_ |= 0x00000008; - stacktrace_ = other.stacktrace_; - onChanged(); - } - if (other.hasMsg()) { - bitField0_ |= 0x00000010; - msg_ = other.msg_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.Test parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.Test) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * <code>optional string name = 1;</code> - */ - public boolean hasName() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string name = 1;</code> - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - name_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string name = 1;</code> - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string name = 1;</code> - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - name_ = value; - onChanged(); - return this; - } - /** - * <code>optional string name = 1;</code> - */ - public Builder clearName() { - bitField0_ = (bitField0_ & ~0x00000001); - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * <code>optional string name = 1;</code> - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - name_ = value; - onChanged(); - return this; - } - - private int status_ = 1; - /** - * <code>optional .TestStatus status = 2;</code> - */ - public boolean hasStatus() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>optional .TestStatus status = 2;</code> - */ - public org.sonar.batch.protocol.Constants.TestStatus getStatus() { - org.sonar.batch.protocol.Constants.TestStatus result = org.sonar.batch.protocol.Constants.TestStatus.valueOf(status_); - return result == null ? org.sonar.batch.protocol.Constants.TestStatus.OK : result; - } - /** - * <code>optional .TestStatus status = 2;</code> - */ - public Builder setStatus(org.sonar.batch.protocol.Constants.TestStatus value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - status_ = value.getNumber(); - onChanged(); - return this; - } - /** - * <code>optional .TestStatus status = 2;</code> - */ - public Builder clearStatus() { - bitField0_ = (bitField0_ & ~0x00000002); - status_ = 1; - onChanged(); - return this; - } - - private long durationInMs_ ; - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - public boolean hasDurationInMs() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - public long getDurationInMs() { - return durationInMs_; - } - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - public Builder setDurationInMs(long value) { - bitField0_ |= 0x00000004; - durationInMs_ = value; - onChanged(); - return this; - } - /** - * <code>optional int64 duration_in_ms = 3;</code> - */ - public Builder clearDurationInMs() { - bitField0_ = (bitField0_ & ~0x00000004); - durationInMs_ = 0L; - onChanged(); - return this; - } - - private java.lang.Object stacktrace_ = ""; - /** - * <code>optional string stacktrace = 4;</code> - */ - public boolean hasStacktrace() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>optional string stacktrace = 4;</code> - */ - public java.lang.String getStacktrace() { - java.lang.Object ref = stacktrace_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - stacktrace_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string stacktrace = 4;</code> - */ - public com.google.protobuf.ByteString - getStacktraceBytes() { - java.lang.Object ref = stacktrace_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - stacktrace_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string stacktrace = 4;</code> - */ - public Builder setStacktrace( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - stacktrace_ = value; - onChanged(); - return this; - } - /** - * <code>optional string stacktrace = 4;</code> - */ - public Builder clearStacktrace() { - bitField0_ = (bitField0_ & ~0x00000008); - stacktrace_ = getDefaultInstance().getStacktrace(); - onChanged(); - return this; - } - /** - * <code>optional string stacktrace = 4;</code> - */ - public Builder setStacktraceBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - stacktrace_ = value; - onChanged(); - return this; - } - - private java.lang.Object msg_ = ""; - /** - * <code>optional string msg = 5;</code> - */ - public boolean hasMsg() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>optional string msg = 5;</code> - */ - public java.lang.String getMsg() { - java.lang.Object ref = msg_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - msg_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string msg = 5;</code> - */ - public com.google.protobuf.ByteString - getMsgBytes() { - java.lang.Object ref = msg_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - msg_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string msg = 5;</code> - */ - public Builder setMsg( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000010; - msg_ = value; - onChanged(); - return this; - } - /** - * <code>optional string msg = 5;</code> - */ - public Builder clearMsg() { - bitField0_ = (bitField0_ & ~0x00000010); - msg_ = getDefaultInstance().getMsg(); - onChanged(); - return this; - } - /** - * <code>optional string msg = 5;</code> - */ - public Builder setMsgBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000010; - msg_ = value; - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:Test) - } - - // @@protoc_insertion_point(class_scope:Test) - private static final org.sonar.batch.protocol.output.BatchReport.Test DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.Test(); - } - - public static org.sonar.batch.protocol.output.BatchReport.Test getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<Test> PARSER = - new com.google.protobuf.AbstractParser<Test>() { - public Test parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new Test(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<Test> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.Test getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface CoverageDetailOrBuilder extends - // @@protoc_insertion_point(interface_extends:CoverageDetail) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional string test_name = 1;</code> - */ - boolean hasTestName(); - /** - * <code>optional string test_name = 1;</code> - */ - java.lang.String getTestName(); - /** - * <code>optional string test_name = 1;</code> - */ - com.google.protobuf.ByteString - getTestNameBytes(); - - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - java.util.List<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile> - getCoveredFileList(); - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile getCoveredFile(int index); - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - int getCoveredFileCount(); - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder> - getCoveredFileOrBuilderList(); - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder getCoveredFileOrBuilder( - int index); - } - /** - * Protobuf type {@code CoverageDetail} - */ - public static final class CoverageDetail extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:CoverageDetail) - CoverageDetailOrBuilder { - // Use CoverageDetail.newBuilder() to construct. - private CoverageDetail(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private CoverageDetail() { - testName_ = ""; - coveredFile_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CoverageDetail( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.protobuf.ByteString bs = input.readBytes(); - bitField0_ |= 0x00000001; - testName_ = bs; - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - coveredFile_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile>(); - mutable_bitField0_ |= 0x00000002; - } - coveredFile_.add(input.readMessage(org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.PARSER, extensionRegistry)); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - coveredFile_ = java.util.Collections.unmodifiableList(coveredFile_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.class, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.Builder.class); - } - - public interface CoveredFileOrBuilder extends - // @@protoc_insertion_point(interface_extends:CoverageDetail.CoveredFile) - com.google.protobuf.MessageOrBuilder { - - /** - * <code>optional int32 file_ref = 1;</code> - */ - boolean hasFileRef(); - /** - * <code>optional int32 file_ref = 1;</code> - */ - int getFileRef(); - - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - java.util.List<java.lang.Integer> getCoveredLineList(); - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - int getCoveredLineCount(); - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - int getCoveredLine(int index); - } - /** - * Protobuf type {@code CoverageDetail.CoveredFile} - */ - public static final class CoveredFile extends - com.google.protobuf.GeneratedMessage implements - // @@protoc_insertion_point(message_implements:CoverageDetail.CoveredFile) - CoveredFileOrBuilder { - // Use CoveredFile.newBuilder() to construct. - private CoveredFile(com.google.protobuf.GeneratedMessage.Builder builder) { - super(builder); - } - private CoveredFile() { - fileRef_ = 0; - coveredLine_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CoveredFile( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) { - this(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - bitField0_ |= 0x00000001; - fileRef_ = input.readInt32(); - break; - } - case 16: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - coveredLine_ = new java.util.ArrayList<java.lang.Integer>(); - mutable_bitField0_ |= 0x00000002; - } - coveredLine_.add(input.readInt32()); - break; - } - case 18: { - int length = input.readRawVarint32(); - int limit = input.pushLimit(length); - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002) && input.getBytesUntilLimit() > 0) { - coveredLine_ = new java.util.ArrayList<java.lang.Integer>(); - mutable_bitField0_ |= 0x00000002; - } - while (input.getBytesUntilLimit() > 0) { - coveredLine_.add(input.readInt32()); - } - input.popLimit(limit); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw new RuntimeException(e.setUnfinishedMessage(this)); - } catch (java.io.IOException e) { - throw new RuntimeException( - new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this)); - } finally { - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - coveredLine_ = java.util.Collections.unmodifiableList(coveredLine_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_CoveredFile_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_CoveredFile_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.class, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder.class); - } - - private int bitField0_; - public static final int FILE_REF_FIELD_NUMBER = 1; - private int fileRef_; - /** - * <code>optional int32 file_ref = 1;</code> - */ - public boolean hasFileRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 file_ref = 1;</code> - */ - public int getFileRef() { - return fileRef_; - } - - public static final int COVERED_LINE_FIELD_NUMBER = 2; - private java.util.List<java.lang.Integer> coveredLine_; - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public java.util.List<java.lang.Integer> - getCoveredLineList() { - return coveredLine_; - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public int getCoveredLineCount() { - return coveredLine_.size(); - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public int getCoveredLine(int index) { - return coveredLine_.get(index); - } - private int coveredLineMemoizedSerializedSize = -1; - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - getSerializedSize(); - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeInt32(1, fileRef_); - } - if (getCoveredLineList().size() > 0) { - output.writeRawVarint32(18); - output.writeRawVarint32(coveredLineMemoizedSerializedSize); - } - for (int i = 0; i < coveredLine_.size(); i++) { - output.writeInt32NoTag(coveredLine_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, fileRef_); - } - { - int dataSize = 0; - for (int i = 0; i < coveredLine_.size(); i++) { - dataSize += com.google.protobuf.CodedOutputStream - .computeInt32SizeNoTag(coveredLine_.get(i)); - } - size += dataSize; - if (!getCoveredLineList().isEmpty()) { - size += 1; - size += com.google.protobuf.CodedOutputStream - .computeInt32SizeNoTag(dataSize); - } - coveredLineMemoizedSerializedSize = dataSize; - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code CoverageDetail.CoveredFile} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:CoverageDetail.CoveredFile) - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_CoveredFile_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_CoveredFile_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.class, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - fileRef_ = 0; - bitField0_ = (bitField0_ & ~0x00000001); - coveredLine_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_CoveredFile_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile build() { - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile buildPartial() { - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile result = new org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.fileRef_ = fileRef_; - if (((bitField0_ & 0x00000002) == 0x00000002)) { - coveredLine_ = java.util.Collections.unmodifiableList(coveredLine_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.coveredLine_ = coveredLine_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile other) { - if (other == org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.getDefaultInstance()) return this; - if (other.hasFileRef()) { - setFileRef(other.getFileRef()); - } - if (!other.coveredLine_.isEmpty()) { - if (coveredLine_.isEmpty()) { - coveredLine_ = other.coveredLine_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureCoveredLineIsMutable(); - coveredLine_.addAll(other.coveredLine_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private int fileRef_ ; - /** - * <code>optional int32 file_ref = 1;</code> - */ - public boolean hasFileRef() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional int32 file_ref = 1;</code> - */ - public int getFileRef() { - return fileRef_; - } - /** - * <code>optional int32 file_ref = 1;</code> - */ - public Builder setFileRef(int value) { - bitField0_ |= 0x00000001; - fileRef_ = value; - onChanged(); - return this; - } - /** - * <code>optional int32 file_ref = 1;</code> - */ - public Builder clearFileRef() { - bitField0_ = (bitField0_ & ~0x00000001); - fileRef_ = 0; - onChanged(); - return this; - } - - private java.util.List<java.lang.Integer> coveredLine_ = java.util.Collections.emptyList(); - private void ensureCoveredLineIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - coveredLine_ = new java.util.ArrayList<java.lang.Integer>(coveredLine_); - bitField0_ |= 0x00000002; - } - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public java.util.List<java.lang.Integer> - getCoveredLineList() { - return java.util.Collections.unmodifiableList(coveredLine_); - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public int getCoveredLineCount() { - return coveredLine_.size(); - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public int getCoveredLine(int index) { - return coveredLine_.get(index); - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public Builder setCoveredLine( - int index, int value) { - ensureCoveredLineIsMutable(); - coveredLine_.set(index, value); - onChanged(); - return this; - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public Builder addCoveredLine(int value) { - ensureCoveredLineIsMutable(); - coveredLine_.add(value); - onChanged(); - return this; - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public Builder addAllCoveredLine( - java.lang.Iterable<? extends java.lang.Integer> values) { - ensureCoveredLineIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, coveredLine_); - onChanged(); - return this; - } - /** - * <code>repeated int32 covered_line = 2 [packed = true];</code> - */ - public Builder clearCoveredLine() { - coveredLine_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - - // @@protoc_insertion_point(builder_scope:CoverageDetail.CoveredFile) - } - - // @@protoc_insertion_point(class_scope:CoverageDetail.CoveredFile) - private static final org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile(); - } - - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<CoveredFile> PARSER = - new com.google.protobuf.AbstractParser<CoveredFile>() { - public CoveredFile parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new CoveredFile(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<CoveredFile> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int bitField0_; - public static final int TEST_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object testName_; - /** - * <code>optional string test_name = 1;</code> - */ - public boolean hasTestName() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string test_name = 1;</code> - */ - public java.lang.String getTestName() { - java.lang.Object ref = testName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - testName_ = s; - } - return s; - } - } - /** - * <code>optional string test_name = 1;</code> - */ - public com.google.protobuf.ByteString - getTestNameBytes() { - java.lang.Object ref = testName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - testName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int COVERED_FILE_FIELD_NUMBER = 2; - private java.util.List<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile> coveredFile_; - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile> getCoveredFileList() { - return coveredFile_; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder> - getCoveredFileOrBuilderList() { - return coveredFile_; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public int getCoveredFileCount() { - return coveredFile_.size(); - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile getCoveredFile(int index) { - return coveredFile_.get(index); - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder getCoveredFileOrBuilder( - int index) { - return coveredFile_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getTestNameBytes()); - } - for (int i = 0; i < coveredFile_.size(); i++) { - output.writeMessage(2, coveredFile_.get(i)); - } - unknownFields.writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getTestNameBytes()); - } - for (int i = 0; i < coveredFile_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, coveredFile_.get(i)); - } - size += unknownFields.getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(org.sonar.batch.protocol.output.BatchReport.CoverageDetail prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code CoverageDetail} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> implements - // @@protoc_insertion_point(builder_implements:CoverageDetail) - org.sonar.batch.protocol.output.BatchReport.CoverageDetailOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.class, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.Builder.class); - } - - // Construct using org.sonar.batch.protocol.output.BatchReport.CoverageDetail.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getCoveredFileFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - testName_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - if (coveredFileBuilder_ == null) { - coveredFile_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - coveredFileBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.sonar.batch.protocol.output.BatchReport.internal_static_CoverageDetail_descriptor; - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail getDefaultInstanceForType() { - return org.sonar.batch.protocol.output.BatchReport.CoverageDetail.getDefaultInstance(); - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail build() { - org.sonar.batch.protocol.output.BatchReport.CoverageDetail result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail buildPartial() { - org.sonar.batch.protocol.output.BatchReport.CoverageDetail result = new org.sonar.batch.protocol.output.BatchReport.CoverageDetail(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.testName_ = testName_; - if (coveredFileBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - coveredFile_ = java.util.Collections.unmodifiableList(coveredFile_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.coveredFile_ = coveredFile_; - } else { - result.coveredFile_ = coveredFileBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.sonar.batch.protocol.output.BatchReport.CoverageDetail) { - return mergeFrom((org.sonar.batch.protocol.output.BatchReport.CoverageDetail)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.sonar.batch.protocol.output.BatchReport.CoverageDetail other) { - if (other == org.sonar.batch.protocol.output.BatchReport.CoverageDetail.getDefaultInstance()) return this; - if (other.hasTestName()) { - bitField0_ |= 0x00000001; - testName_ = other.testName_; - onChanged(); - } - if (coveredFileBuilder_ == null) { - if (!other.coveredFile_.isEmpty()) { - if (coveredFile_.isEmpty()) { - coveredFile_ = other.coveredFile_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureCoveredFileIsMutable(); - coveredFile_.addAll(other.coveredFile_); - } - onChanged(); - } - } else { - if (!other.coveredFile_.isEmpty()) { - if (coveredFileBuilder_.isEmpty()) { - coveredFileBuilder_.dispose(); - coveredFileBuilder_ = null; - coveredFile_ = other.coveredFile_; - bitField0_ = (bitField0_ & ~0x00000002); - coveredFileBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getCoveredFileFieldBuilder() : null; - } else { - coveredFileBuilder_.addAllMessages(other.coveredFile_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.sonar.batch.protocol.output.BatchReport.CoverageDetail parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.sonar.batch.protocol.output.BatchReport.CoverageDetail) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object testName_ = ""; - /** - * <code>optional string test_name = 1;</code> - */ - public boolean hasTestName() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>optional string test_name = 1;</code> - */ - public java.lang.String getTestName() { - java.lang.Object ref = testName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - testName_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>optional string test_name = 1;</code> - */ - public com.google.protobuf.ByteString - getTestNameBytes() { - java.lang.Object ref = testName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - testName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>optional string test_name = 1;</code> - */ - public Builder setTestName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - testName_ = value; - onChanged(); - return this; - } - /** - * <code>optional string test_name = 1;</code> - */ - public Builder clearTestName() { - bitField0_ = (bitField0_ & ~0x00000001); - testName_ = getDefaultInstance().getTestName(); - onChanged(); - return this; - } - /** - * <code>optional string test_name = 1;</code> - */ - public Builder setTestNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - testName_ = value; - onChanged(); - return this; - } - - private java.util.List<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile> coveredFile_ = - java.util.Collections.emptyList(); - private void ensureCoveredFileIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - coveredFile_ = new java.util.ArrayList<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile>(coveredFile_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder> coveredFileBuilder_; - - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile> getCoveredFileList() { - if (coveredFileBuilder_ == null) { - return java.util.Collections.unmodifiableList(coveredFile_); - } else { - return coveredFileBuilder_.getMessageList(); - } - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public int getCoveredFileCount() { - if (coveredFileBuilder_ == null) { - return coveredFile_.size(); - } else { - return coveredFileBuilder_.getCount(); - } - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile getCoveredFile(int index) { - if (coveredFileBuilder_ == null) { - return coveredFile_.get(index); - } else { - return coveredFileBuilder_.getMessage(index); - } - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder setCoveredFile( - int index, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile value) { - if (coveredFileBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCoveredFileIsMutable(); - coveredFile_.set(index, value); - onChanged(); - } else { - coveredFileBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder setCoveredFile( - int index, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder builderForValue) { - if (coveredFileBuilder_ == null) { - ensureCoveredFileIsMutable(); - coveredFile_.set(index, builderForValue.build()); - onChanged(); - } else { - coveredFileBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder addCoveredFile(org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile value) { - if (coveredFileBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCoveredFileIsMutable(); - coveredFile_.add(value); - onChanged(); - } else { - coveredFileBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder addCoveredFile( - int index, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile value) { - if (coveredFileBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCoveredFileIsMutable(); - coveredFile_.add(index, value); - onChanged(); - } else { - coveredFileBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder addCoveredFile( - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder builderForValue) { - if (coveredFileBuilder_ == null) { - ensureCoveredFileIsMutable(); - coveredFile_.add(builderForValue.build()); - onChanged(); - } else { - coveredFileBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder addCoveredFile( - int index, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder builderForValue) { - if (coveredFileBuilder_ == null) { - ensureCoveredFileIsMutable(); - coveredFile_.add(index, builderForValue.build()); - onChanged(); - } else { - coveredFileBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder addAllCoveredFile( - java.lang.Iterable<? extends org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile> values) { - if (coveredFileBuilder_ == null) { - ensureCoveredFileIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, coveredFile_); - onChanged(); - } else { - coveredFileBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder clearCoveredFile() { - if (coveredFileBuilder_ == null) { - coveredFile_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - coveredFileBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public Builder removeCoveredFile(int index) { - if (coveredFileBuilder_ == null) { - ensureCoveredFileIsMutable(); - coveredFile_.remove(index); - onChanged(); - } else { - coveredFileBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder getCoveredFileBuilder( - int index) { - return getCoveredFileFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder getCoveredFileOrBuilder( - int index) { - if (coveredFileBuilder_ == null) { - return coveredFile_.get(index); } else { - return coveredFileBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public java.util.List<? extends org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder> - getCoveredFileOrBuilderList() { - if (coveredFileBuilder_ != null) { - return coveredFileBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(coveredFile_); - } - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder addCoveredFileBuilder() { - return getCoveredFileFieldBuilder().addBuilder( - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.getDefaultInstance()); - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder addCoveredFileBuilder( - int index) { - return getCoveredFileFieldBuilder().addBuilder( - index, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.getDefaultInstance()); - } - /** - * <code>repeated .CoverageDetail.CoveredFile covered_file = 2;</code> - */ - public java.util.List<org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder> - getCoveredFileBuilderList() { - return getCoveredFileFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder> - getCoveredFileFieldBuilder() { - if (coveredFileBuilder_ == null) { - coveredFileBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFile.Builder, org.sonar.batch.protocol.output.BatchReport.CoverageDetail.CoveredFileOrBuilder>( - coveredFile_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - coveredFile_ = null; - } - return coveredFileBuilder_; - } - - // @@protoc_insertion_point(builder_scope:CoverageDetail) - } - - // @@protoc_insertion_point(class_scope:CoverageDetail) - private static final org.sonar.batch.protocol.output.BatchReport.CoverageDetail DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new org.sonar.batch.protocol.output.BatchReport.CoverageDetail(); - } - - public static org.sonar.batch.protocol.output.BatchReport.CoverageDetail getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - public static final com.google.protobuf.Parser<CoverageDetail> PARSER = - new com.google.protobuf.AbstractParser<CoverageDetail>() { - public CoverageDetail parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - try { - return new CoverageDetail(input, extensionRegistry); - } catch (RuntimeException e) { - if (e.getCause() instanceof - com.google.protobuf.InvalidProtocolBufferException) { - throw (com.google.protobuf.InvalidProtocolBufferException) - e.getCause(); - } - throw e; - } - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<CoverageDetail> getParserForType() { - return PARSER; - } - - public org.sonar.batch.protocol.output.BatchReport.CoverageDetail getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Metadata_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Metadata_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_ActiveRule_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_ActiveRule_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_ActiveRule_ActiveRuleParam_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_ActiveRule_ActiveRuleParam_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_ComponentLink_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_ComponentLink_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Component_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Component_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Measure_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Measure_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Issue_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Issue_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_IssueLocation_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_IssueLocation_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Flow_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Flow_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Changesets_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Changesets_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Changesets_Changeset_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Changesets_Changeset_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Duplicate_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Duplicate_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Duplication_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Duplication_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_TextRange_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_TextRange_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Symbol_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Symbol_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Coverage_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Coverage_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_SyntaxHighlighting_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_SyntaxHighlighting_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_Test_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_Test_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_CoverageDetail_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_CoverageDetail_fieldAccessorTable; - private static com.google.protobuf.Descriptors.Descriptor - internal_static_CoverageDetail_CoveredFile_descriptor; - private static - com.google.protobuf.GeneratedMessage.FieldAccessorTable - internal_static_CoverageDetail_CoveredFile_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n\022batch_report.proto\032\017constants.proto\"b\n" + - "\010Metadata\022\025\n\ranalysis_date\030\001 \001(\003\022\023\n\013proj" + - "ect_key\030\002 \001(\t\022\016\n\006branch\030\003 \001(\t\022\032\n\022root_co" + - "mponent_ref\030\004 \001(\005\"\257\001\n\nActiveRule\022\027\n\017rule" + - "_repository\030\001 \001(\t\022\020\n\010rule_key\030\002 \001(\t\022\033\n\010s" + - "everity\030\003 \001(\0162\t.Severity\022*\n\005param\030\004 \003(\0132" + - "\033.ActiveRule.ActiveRuleParam\032-\n\017ActiveRu" + - "leParam\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t\"?\n\rC" + - "omponentLink\022 \n\004type\030\001 \001(\0162\022.ComponentLi" + - "nkType\022\014\n\004href\030\002 \001(\t\"\354\001\n\tComponent\022\013\n\003re", - "f\030\001 \001(\005\022\014\n\004path\030\002 \001(\t\022\014\n\004name\030\003 \001(\t\022\034\n\004t" + - "ype\030\004 \001(\0162\016.ComponentType\022\017\n\007is_test\030\005 \001" + - "(\010\022\020\n\010language\030\006 \001(\t\022\025\n\tchild_ref\030\007 \003(\005B" + - "\002\020\001\022\034\n\004link\030\010 \003(\0132\016.ComponentLink\022\017\n\007ver" + - "sion\030\t \001(\t\022\013\n\003key\030\n \001(\t\022\r\n\005lines\030\013 \001(\005\022\023" + - "\n\013description\030\014 \001(\t\"\256\001\n\007Measure\022%\n\nvalue" + - "_type\030\001 \001(\0162\021.MeasureValueType\022\025\n\rboolea" + - "n_value\030\002 \001(\010\022\021\n\tint_value\030\003 \001(\005\022\022\n\nlong" + - "_value\030\004 \001(\003\022\024\n\014double_value\030\005 \001(\001\022\024\n\014st" + - "ring_value\030\006 \001(\t\022\022\n\nmetric_key\030\007 \001(\t\"\266\001\n", - "\005Issue\022\027\n\017rule_repository\030\001 \001(\t\022\020\n\010rule_" + - "key\030\002 \001(\t\022\014\n\004line\030\003 \001(\005\022\013\n\003msg\030\004 \001(\t\022\033\n\010" + - "severity\030\005 \001(\0162\t.Severity\022\025\n\reffort_to_f" + - "ix\030\006 \001(\001\022\036\n\ntext_range\030\007 \001(\0132\n.TextRange" + - "\022\023\n\004flow\030\010 \003(\0132\005.Flow\"S\n\rIssueLocation\022\025" + - "\n\rcomponent_ref\030\001 \001(\005\022\036\n\ntext_range\030\002 \001(" + - "\0132\n.TextRange\022\013\n\003msg\030\003 \001(\t\"(\n\004Flow\022 \n\010lo" + - "cation\030\001 \003(\0132\016.IssueLocation\"\254\001\n\nChanges" + - "ets\022\025\n\rcomponent_ref\030\001 \001(\005\022(\n\tchangeset\030" + - "\002 \003(\0132\025.Changesets.Changeset\022 \n\024changese", - "tIndexByLine\030\003 \003(\005B\002\020\001\032;\n\tChangeset\022\020\n\010r" + - "evision\030\001 \001(\t\022\016\n\006author\030\002 \001(\t\022\014\n\004date\030\003 " + - "\001(\003\"V\n\tDuplicate\022\026\n\016other_file_ref\030\001 \001(\005" + - "\022\031\n\005range\030\002 \001(\0132\n.TextRange\022\026\n\016other_fil" + - "e_key\030\003 \001(\t\"Q\n\013Duplication\022#\n\017origin_pos" + - "ition\030\001 \001(\0132\n.TextRange\022\035\n\tduplicate\030\002 \003" + - "(\0132\n.Duplicate\"[\n\tTextRange\022\022\n\nstart_lin" + - "e\030\001 \001(\005\022\020\n\010end_line\030\002 \001(\005\022\024\n\014start_offse" + - "t\030\003 \001(\005\022\022\n\nend_offset\030\004 \001(\005\"H\n\006Symbol\022\037\n" + - "\013declaration\030\001 \001(\0132\n.TextRange\022\035\n\trefere", - "nce\030\002 \003(\0132\n.TextRange\"\260\001\n\010Coverage\022\014\n\004li" + - "ne\030\001 \001(\005\022\022\n\nconditions\030\002 \001(\005\022\017\n\007ut_hits\030" + - "\003 \001(\010\022\017\n\007it_hits\030\004 \001(\010\022\035\n\025ut_covered_con" + - "ditions\030\005 \001(\005\022\035\n\025it_covered_conditions\030\006" + - " \001(\005\022\"\n\032overall_covered_conditions\030\007 \001(\005" + - "\"P\n\022SyntaxHighlighting\022\031\n\005range\030\001 \001(\0132\n." + - "TextRange\022\037\n\004type\030\002 \001(\0162\021.HighlightingTy" + - "pe\"j\n\004Test\022\014\n\004name\030\001 \001(\t\022\033\n\006status\030\002 \001(\016" + - "2\013.TestStatus\022\026\n\016duration_in_ms\030\003 \001(\003\022\022\n" + - "\nstacktrace\030\004 \001(\t\022\013\n\003msg\030\005 \001(\t\"\221\001\n\016Cover", - "ageDetail\022\021\n\ttest_name\030\001 \001(\t\0221\n\014covered_" + - "file\030\002 \003(\0132\033.CoverageDetail.CoveredFile\032" + - "9\n\013CoveredFile\022\020\n\010file_ref\030\001 \001(\005\022\030\n\014cove" + - "red_line\030\002 \003(\005B\002\020\001B#\n\037org.sonar.batch.pr" + - "otocol.outputH\001" - }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - org.sonar.batch.protocol.Constants.getDescriptor(), - }, assigner); - internal_static_Metadata_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_Metadata_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Metadata_descriptor, - new java.lang.String[] { "AnalysisDate", "ProjectKey", "Branch", "RootComponentRef", }); - internal_static_ActiveRule_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_ActiveRule_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_ActiveRule_descriptor, - new java.lang.String[] { "RuleRepository", "RuleKey", "Severity", "Param", }); - internal_static_ActiveRule_ActiveRuleParam_descriptor = - internal_static_ActiveRule_descriptor.getNestedTypes().get(0); - internal_static_ActiveRule_ActiveRuleParam_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_ActiveRule_ActiveRuleParam_descriptor, - new java.lang.String[] { "Key", "Value", }); - internal_static_ComponentLink_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_ComponentLink_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_ComponentLink_descriptor, - new java.lang.String[] { "Type", "Href", }); - internal_static_Component_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_Component_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Component_descriptor, - new java.lang.String[] { "Ref", "Path", "Name", "Type", "IsTest", "Language", "ChildRef", "Link", "Version", "Key", "Lines", "Description", }); - internal_static_Measure_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_Measure_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Measure_descriptor, - new java.lang.String[] { "ValueType", "BooleanValue", "IntValue", "LongValue", "DoubleValue", "StringValue", "MetricKey", }); - internal_static_Issue_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_Issue_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Issue_descriptor, - new java.lang.String[] { "RuleRepository", "RuleKey", "Line", "Msg", "Severity", "EffortToFix", "TextRange", "Flow", }); - internal_static_IssueLocation_descriptor = - getDescriptor().getMessageTypes().get(6); - internal_static_IssueLocation_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_IssueLocation_descriptor, - new java.lang.String[] { "ComponentRef", "TextRange", "Msg", }); - internal_static_Flow_descriptor = - getDescriptor().getMessageTypes().get(7); - internal_static_Flow_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Flow_descriptor, - new java.lang.String[] { "Location", }); - internal_static_Changesets_descriptor = - getDescriptor().getMessageTypes().get(8); - internal_static_Changesets_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Changesets_descriptor, - new java.lang.String[] { "ComponentRef", "Changeset", "ChangesetIndexByLine", }); - internal_static_Changesets_Changeset_descriptor = - internal_static_Changesets_descriptor.getNestedTypes().get(0); - internal_static_Changesets_Changeset_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Changesets_Changeset_descriptor, - new java.lang.String[] { "Revision", "Author", "Date", }); - internal_static_Duplicate_descriptor = - getDescriptor().getMessageTypes().get(9); - internal_static_Duplicate_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Duplicate_descriptor, - new java.lang.String[] { "OtherFileRef", "Range", "OtherFileKey", }); - internal_static_Duplication_descriptor = - getDescriptor().getMessageTypes().get(10); - internal_static_Duplication_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Duplication_descriptor, - new java.lang.String[] { "OriginPosition", "Duplicate", }); - internal_static_TextRange_descriptor = - getDescriptor().getMessageTypes().get(11); - internal_static_TextRange_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_TextRange_descriptor, - new java.lang.String[] { "StartLine", "EndLine", "StartOffset", "EndOffset", }); - internal_static_Symbol_descriptor = - getDescriptor().getMessageTypes().get(12); - internal_static_Symbol_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Symbol_descriptor, - new java.lang.String[] { "Declaration", "Reference", }); - internal_static_Coverage_descriptor = - getDescriptor().getMessageTypes().get(13); - internal_static_Coverage_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Coverage_descriptor, - new java.lang.String[] { "Line", "Conditions", "UtHits", "ItHits", "UtCoveredConditions", "ItCoveredConditions", "OverallCoveredConditions", }); - internal_static_SyntaxHighlighting_descriptor = - getDescriptor().getMessageTypes().get(14); - internal_static_SyntaxHighlighting_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_SyntaxHighlighting_descriptor, - new java.lang.String[] { "Range", "Type", }); - internal_static_Test_descriptor = - getDescriptor().getMessageTypes().get(15); - internal_static_Test_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_Test_descriptor, - new java.lang.String[] { "Name", "Status", "DurationInMs", "Stacktrace", "Msg", }); - internal_static_CoverageDetail_descriptor = - getDescriptor().getMessageTypes().get(16); - internal_static_CoverageDetail_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_CoverageDetail_descriptor, - new java.lang.String[] { "TestName", "CoveredFile", }); - internal_static_CoverageDetail_CoveredFile_descriptor = - internal_static_CoverageDetail_descriptor.getNestedTypes().get(0); - internal_static_CoverageDetail_CoveredFile_fieldAccessorTable = new - com.google.protobuf.GeneratedMessage.FieldAccessorTable( - internal_static_CoverageDetail_CoveredFile_descriptor, - new java.lang.String[] { "FileRef", "CoveredLine", }); - org.sonar.batch.protocol.Constants.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/sonar-batch-protocol/src/main/protobuf/batch_input.proto b/sonar-batch-protocol/src/main/protobuf/batch_input.proto index 84a9c53d812..06edb314b5e 100644 --- a/sonar-batch-protocol/src/main/protobuf/batch_input.proto +++ b/sonar-batch-protocol/src/main/protobuf/batch_input.proto @@ -24,10 +24,6 @@ Notes - this is beta version of specification. It will evolve during next releases and is not forward-compatible yet. - - - the related Java files are not generated during build. Indeed the existing protoc maven - plugins require protobuf to be installed on boxes. That means that generated Java files - are updated and committed for each change (see src/main/gen-java). */ syntax = "proto2"; diff --git a/sonar-batch-protocol/src/main/protobuf/batch_report.proto b/sonar-batch-protocol/src/main/protobuf/batch_report.proto index 631c2c4ae49..ffb4f241b9f 100644 --- a/sonar-batch-protocol/src/main/protobuf/batch_report.proto +++ b/sonar-batch-protocol/src/main/protobuf/batch_report.proto @@ -24,10 +24,6 @@ Notes - this is beta version of specification. It will evolve during next releases and is not forward-compatible yet. - - - the related Java files are not generated during build. Indeed the existing protoc maven - plugins require protobuf to be installed on boxes. That means that generated Java files - are updated and committed for each change (see src/main/gen-java). */ syntax = "proto2"; |