private void mergeLocalToBuilder() { if (this.resource != null && !((LocalResourcePBImpl)this.resource).getProto() .equals(builder.getResource())) { builder.setResource(convertToProtoFormat(this.resource)); } if (this.localPath != null && !((URLPBImpl)this.localPath).getProto() .equals(builder.getLocalPath())) { builder.setLocalPath(convertToProtoFormat(this.localPath)); } if (this.exception != null && !((SerializedExceptionPBImpl)this.exception).getProto() .equals(builder.getException())) { builder.setException(convertToProtoFormat(this.exception)); } }
private void mergeLocalToBuilder() { ResourceLocalizationSpecProtoOrBuilder l = viaProto ? proto : builder; if (this.resource != null && !(l.getResource() .equals(((LocalResourcePBImpl) resource).getProto()))) { maybeInitBuilder(); builder.setResource(((LocalResourcePBImpl) resource).getProto()); } if (this.destinationDirectory != null && !(l.getDestinationDirectory() .equals(((URLPBImpl) destinationDirectory).getProto()))) { maybeInitBuilder(); builder.setDestinationDirectory(((URLPBImpl) destinationDirectory) .getProto()); } }
private URLPBImpl convertFromProtoFormat(URLProto p) { return new URLPBImpl(p); }
private URLProto convertToProtoFormat(URL t) { return ((URLPBImpl)t).getProto(); }
@Test public void testURLPBImpl() throws Exception { validatePBImplRecord(URLPBImpl.class, URLProto.class); }