@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.logging.v2.LogEntrySourceLocation)) { return super.equals(obj); } com.google.logging.v2.LogEntrySourceLocation other = (com.google.logging.v2.LogEntrySourceLocation) obj; boolean result = true; result = result && getFile().equals(other.getFile()); result = result && (getLine() == other.getLine()); result = result && getFunction().equals(other.getFunction()); result = result && unknownFields.equals(other.unknownFields); return result; }
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + FILE_FIELD_NUMBER; hash = (53 * hash) + getFile().hashCode(); hash = (37 * hash) + LINE_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getLine()); hash = (37 * hash) + FUNCTION_FIELD_NUMBER; hash = (53 * hash) + getFunction().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
/** * * * <pre> * Optional. Human-readable name of the function or method being invoked, with * optional context such as the class or package name. This information may be * used in contexts such as the logs viewer, where a file and line number are * less meaningful. The format can vary by language. For example: * `qual.if.ied.Class.method` (Java), `dir/package.func` (Go), `function` * (Python). * </pre> * * <code>string function = 3;</code> */ public Builder clearFunction() { function_ = getDefaultInstance().getFunction(); onChanged(); return this; } /**
public Builder mergeFrom(com.google.logging.v2.LogEntrySourceLocation other) { if (other == com.google.logging.v2.LogEntrySourceLocation.getDefaultInstance()) return this; if (!other.getFile().isEmpty()) { file_ = other.file_; onChanged(); } if (other.getLine() != 0L) { setLine(other.getLine()); } if (!other.getFunction().isEmpty()) { function_ = other.function_; onChanged(); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
static SourceLocation fromPb(LogEntrySourceLocation sourceLocationPb) { return new Builder() .setFile(sourceLocationPb.getFile()) .setLine(sourceLocationPb.getLine()) .setFunction(sourceLocationPb.getFunction()) .build(); } }
static SourceLocation fromPb(LogEntrySourceLocation sourceLocationPb) { return new Builder() .setFile(sourceLocationPb.getFile()) .setLine(sourceLocationPb.getLine()) .setFunction(sourceLocationPb.getFunction()) .build(); } }