@Override public synchronized URL getResource() { LocalResourceProtoOrBuilder p = viaProto ? proto : builder; if (this.url != null) { return this.url; } if (!p.hasResource()) { return null; } this.url = convertFromProtoFormat(p.getResource()); return this.url; }
private synchronized void mergeLocalToBuilder() { LocalResourceProtoOrBuilder l = viaProto ? proto : builder; if (this.url != null && !(l.getResource().equals(((URLPBImpl) url).getProto()))) { maybeInitBuilder(); l = builder; builder.setResource(convertToProtoFormat(this.url)); } }
@Override public synchronized LocalResourceType getType() { LocalResourceProtoOrBuilder p = viaProto ? proto : builder; if (!p.hasType()) { return null; } return convertFromProtoFormat(p.getType()); }
@Override public synchronized LocalResourceVisibility getVisibility() { LocalResourceProtoOrBuilder p = viaProto ? proto : builder; if (!p.hasVisibility()) { return null; } return convertFromProtoFormat(p.getVisibility()); }
@Override public synchronized String getPattern() { LocalResourceProtoOrBuilder p = viaProto ? proto : builder; if (!p.hasPattern()) { return null; } return p.getPattern(); }
@Override public synchronized boolean getShouldBeUploadedToSharedCache() { LocalResourceProtoOrBuilder p = viaProto ? proto : builder; if (!p.hasShouldBeUploadedToSharedCache()) { return false; } return p.getShouldBeUploadedToSharedCache(); }