public Resource(FilePayload payload) { this(payload.getRawContent().getName(), null, payload.getContentMetadata().getContentMD5(), payload .getRawContent().getPath(), "default"); }
public Resource(FilePayload payload) { this(payload.getRawContent().getName(), null, payload.getContentMetadata().getContentMD5(), payload .getRawContent().getPath(), "default"); }
public Builder fromPayload(FilePayload payload) { checkNotNull(payload, "payload"); this.name(payload.getRawContent().getName()); this.checksum(payload.getContentMetadata().getContentMD5()); this.path(payload.getRawContent().getPath()); return this; }
public Builder fromPayload(FilePayload payload) { checkNotNull(payload, "payload"); this.name(payload.getRawContent().getName()); this.checksum(payload.getContentMetadata().getContentMD5()); this.path(payload.getRawContent().getPath()); return this; }
public static Part.PartMap create(String name, Payload delegate, Part.PartOptions options) { String filename = options != null ? options.getFilename() : null; if (delegate instanceof FilePayload) filename = FilePayload.class.cast(delegate).getRawContent().getName(); Part.PartMap returnVal; returnVal = (filename != null) ? create(name, filename) : create(name); if (options != null) returnVal.contentType(options.getContentType()); return returnVal; } }
public static Part.PartMap create(String name, Payload delegate, Part.PartOptions options) { String filename = options != null ? options.getFilename() : null; if (delegate instanceof FilePayload) filename = FilePayload.class.cast(delegate).getRawContent().getName(); Part.PartMap returnVal; returnVal = (filename != null) ? create(name, filename) : create(name); if (options != null) returnVal.contentType(options.getContentType()); return returnVal; } }
public static Part.PartMap create(String name, Payload delegate, Part.PartOptions options) { String filename = options != null ? options.getFilename() : null; if (delegate instanceof FilePayload) filename = FilePayload.class.cast(delegate).getRawContent().getName(); Part.PartMap returnVal; returnVal = (filename != null) ? create(name, filename) : create(name); if (options != null) returnVal.contentType(options.getContentType()); return returnVal; } }
public static Part.PartMap create(String name, Payload delegate, Part.PartOptions options) { String filename = options != null ? options.getFilename() : null; if (delegate instanceof FilePayload) filename = FilePayload.class.cast(delegate).getRawContent().getName(); Part.PartMap returnVal; returnVal = (filename != null) ? create(name, filename) : create(name); if (options != null) returnVal.contentType(options.getContentType()); return returnVal; } }
public static Part.PartMap create(String name, Payload delegate, Part.PartOptions options) { String filename = options != null ? options.getFilename() : null; if (delegate instanceof FilePayload) filename = FilePayload.class.cast(delegate).getRawContent().getName(); Part.PartMap returnVal; returnVal = (filename != null) ? create(name, filename) : create(name); if (options != null) returnVal.contentType(options.getContentType()); return returnVal; } }
public static Part.PartMap create(String name, Payload delegate, Part.PartOptions options) { String filename = options != null ? options.getFilename() : null; if (delegate instanceof FilePayload) filename = FilePayload.class.cast(delegate).getRawContent().getName(); Part.PartMap returnVal; returnVal = (filename != null) ? create(name, filename) : create(name); if (options != null) returnVal.contentType(options.getContentType()); return returnVal; } }