@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (hasKey()) { hash = (37 * hash) + KEY_FIELD_NUMBER; hash = (53 * hash) + getKey().hashCode(); } if (hasValue()) { hash = (37 * hash) + VALUE_FIELD_NUMBER; hash = (53 * hash) + getValue().hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof alluxio.proto.journal.File.StringPairEntry)) { return super.equals(obj); } alluxio.proto.journal.File.StringPairEntry other = (alluxio.proto.journal.File.StringPairEntry) obj; boolean result = true; result = result && (hasKey() == other.hasKey()); if (hasKey()) { result = result && getKey() .equals(other.getKey()); } result = result && (hasValue() == other.hasValue()); if (hasValue()) { result = result && getValue() .equals(other.getValue()); } result = result && unknownFields.equals(other.unknownFields); return result; }
/** * Creates a new instance of {@link MountOptions} from {@link File.AddMountPointEntry}. * * @param options Proto options */ public MountOptions(File.AddMountPointEntry options) { this(); if (options != null) { if (options.hasReadOnly()) { mReadOnly = options.getReadOnly(); } for (File.StringPairEntry entry : options.getPropertiesList()) { mProperties.put(entry.getKey(), entry.getValue()); } if (options.hasShared()) { mShared = options.getShared(); } } }
/** * <code>optional string key = 1;</code> */ public Builder clearKey() { bitField0_ = (bitField0_ & ~0x00000001); key_ = getDefaultInstance().getKey(); onChanged(); return this; } /**
/** * Creates mount proto options from {@link File.AddMountPointEntry}. * @param mountEntryPoint mount point entry * @return created mount proto options */ public static MountPOptions fromMountEntry(File.AddMountPointEntry mountEntryPoint) { MountPOptions.Builder optionsBuilder = MountPOptions.newBuilder(); if (mountEntryPoint != null) { if (mountEntryPoint.hasReadOnly()) { optionsBuilder.setReadOnly(mountEntryPoint.getReadOnly()); } for (File.StringPairEntry entry : mountEntryPoint.getPropertiesList()) { optionsBuilder.putProperties(entry.getKey(), entry.getValue()); } if (mountEntryPoint.hasShared()) { optionsBuilder.setShared(mountEntryPoint.getShared()); } } return optionsBuilder.build(); }
/** * <code>optional string key = 1;</code> */ public Builder clearKey() { bitField0_ = (bitField0_ & ~0x00000001); key_ = getDefaultInstance().getKey(); onChanged(); return this; } /**