public static final class BlobElementsUploadFileCreateElementRequest.Builder extends Object
| Modifier and Type | Method | Description |
|---|---|---|
Boolean |
allowFaultyParts() |
Get If not specified or if specified as false, bodies to be imported are examined for validity and any found to be faulty are removed from the import.
|
BlobElementsUploadFileCreateElementRequest.Builder |
allowFaultyParts(Boolean value) |
Set If not specified or if specified as false, bodies to be imported are examined for validity and any found to be faulty are removed from the import.
|
BlobElementsUploadFileCreateElementResponse |
call(OnshapeDocument document) |
Calls uploadFileCreateElement method, Create a blob element from an uploaded file.
|
BlobElementsUploadFileCreateElementResponse |
call(String did,
String wid) |
Calls uploadFileCreateElement method, Create a blob element from an uploaded file.
|
Boolean |
createComposite() |
Get If the value is specified as true, each part studio contains a single composite part made up of all its topologies.
|
BlobElementsUploadFileCreateElementRequest.Builder |
createComposite(Boolean value) |
Set If the value is specified as true, each part studio contains a single composite part made up of all its topologies.
|
Boolean |
createDrawingIfPossible() |
Get If true and the uploaded file is a DXF or a DWG, automatically create a Drawing element along with the Blob element.
|
BlobElementsUploadFileCreateElementRequest.Builder |
createDrawingIfPossible(Boolean value) |
Set If true and the uploaded file is a DXF or a DWG, automatically create a Drawing element along with the Blob element.
|
String |
encodedFilename() |
Get Filename override interpreted as a URL-encoded string.
|
BlobElementsUploadFileCreateElementRequest.Builder |
encodedFilename(String value) |
Set Filename override interpreted as a URL-encoded string.
|
Blob |
file() |
Get File data to upload.
|
BlobElementsUploadFileCreateElementRequest.Builder |
file(Blob value) |
Set File data to upload.
|
Number |
fileContentLength() |
Get The length of the file being uploaded, in bytes.
|
BlobElementsUploadFileCreateElementRequest.Builder |
fileContentLength(Number value) |
Set The length of the file being uploaded, in bytes.
|
Boolean |
flattenAssemblies() |
Get If true, remove assembly structure and create only a Part Studio
|
BlobElementsUploadFileCreateElementRequest.Builder |
flattenAssemblies(Boolean value) |
Set If true, remove assembly structure and create only a Part Studio
|
Boolean |
importInBackground() |
Get If storeInDocument is true and formatName is ONSHAPE and the source is a Parasolid file, this specifies the preference as to whether the import should be completed prior to the completion of the request (importInBackground=false) or whether it should be performed asynchronously (importInBackground=true).
|
BlobElementsUploadFileCreateElementRequest.Builder |
importInBackground(Boolean value) |
Set If storeInDocument is true and formatName is ONSHAPE and the source is a Parasolid file, this specifies the preference as to whether the import should be completed prior to the completion of the request (importInBackground=false) or whether it should be performed asynchronously (importInBackground=true).
|
String |
locationElementId() |
Get Id of an element to place the new element near.
|
BlobElementsUploadFileCreateElementRequest.Builder |
locationElementId(String value) |
Set Id of an element to place the new element near.
|
String |
locationGroupId() |
Get For internal use.
|
BlobElementsUploadFileCreateElementRequest.Builder |
locationGroupId(String value) |
Set For internal use.
|
Number |
locationPosition() |
Get An indicator for the relative placement of the new element.
|
BlobElementsUploadFileCreateElementRequest.Builder |
locationPosition(Number value) |
Set An indicator for the relative placement of the new element.
|
Boolean |
translate() |
Get Whether the uploaded file should be translated to Onshape format, if possible
|
BlobElementsUploadFileCreateElementRequest.Builder |
translate(Boolean value) |
Set Whether the uploaded file should be translated to Onshape format, if possible
|
Boolean |
yAxisIsUp() |
Get If true, treat the model's Y axis as the vertical axis.
|
BlobElementsUploadFileCreateElementRequest.Builder |
yAxisIsUp(Boolean value) |
Set If true, treat the model's Y axis as the vertical axis.
|
public final Boolean createDrawingIfPossible()
public final BlobElementsUploadFileCreateElementRequest.Builder createDrawingIfPossible(Boolean value)
value - If true and the uploaded file is a DXF or a DWG, automatically create a Drawing element along with the Blob element. Otherwise, just create the Blob element.public final Blob file()
public final BlobElementsUploadFileCreateElementRequest.Builder file(Blob value)
value - File data to upload. This field should normally have a Content-Disposition header field with a "filename" attribute, naming the uploaded file.public final String encodedFilename()
public final BlobElementsUploadFileCreateElementRequest.Builder encodedFilename(String value)
value - Filename override interpreted as a URL-encoded string. If specified, this overrides the filename from a Content-Disposition in the file field.public final Number fileContentLength()
public final BlobElementsUploadFileCreateElementRequest.Builder fileContentLength(Number value)
value - The length of the file being uploaded, in bytes. If not present, Onshape may restrict the upload size under some operating conditions, as the file contents may need to be buffered in memory. If specified, it should be the actual length of the data being uploaded.public final Boolean translate()
public final BlobElementsUploadFileCreateElementRequest.Builder translate(Boolean value)
value - Whether the uploaded file should be translated to Onshape format, if possiblepublic final Boolean flattenAssemblies()
public final BlobElementsUploadFileCreateElementRequest.Builder flattenAssemblies(Boolean value)
value - If true, remove assembly structure and create only a Part Studiopublic final Boolean yAxisIsUp()
public final BlobElementsUploadFileCreateElementRequest.Builder yAxisIsUp(Boolean value)
value - If true, treat the model's Y axis as the vertical axis. Otherwise, Z is treated as the vertical axis.public final Boolean importInBackground()
public final BlobElementsUploadFileCreateElementRequest.Builder importInBackground(Boolean value)
value - If storeInDocument is true and formatName is ONSHAPE and the source is a Parasolid file, this specifies the preference as to whether the import should be completed prior to the completion of the request (importInBackground=false) or whether it should be performed asynchronously (importInBackground=true). Historically, this parameter was implicitly set to false, but large imports can take long enough that the request could result in a timeout. Applications are encouraged to set this parameter to true for reliable operation.public final Boolean allowFaultyParts()
public final BlobElementsUploadFileCreateElementRequest.Builder allowFaultyParts(Boolean value)
value - If not specified or if specified as false, bodies to be imported are examined for validity and any found to be faulty are removed from the import. If all bodies are found to be faulty, the import fails. If the value is specified as true, we attempt to import the bodies that appear to have faults.public final Boolean createComposite()
public final BlobElementsUploadFileCreateElementRequest.Builder createComposite(Boolean value)
value - If the value is specified as true, each part studio contains a single composite part made up of all its topologies.public final String locationGroupId()
public final BlobElementsUploadFileCreateElementRequest.Builder locationGroupId(String value)
value - For internal use.public final String locationElementId()
public final BlobElementsUploadFileCreateElementRequest.Builder locationElementId(String value)
value - Id of an element to place the new element near.public final Number locationPosition()
public final BlobElementsUploadFileCreateElementRequest.Builder locationPosition(Number value)
value - An indicator for the relative placement of the new element. If locationElementId is specified, a negative number indicates insertion prior to the element and a non-negative number indicates insertion following the element. If no elementId is specified, a negative value indicates insertion at the end of the group or element list and a non-negative number indicates insertion at the start of the group or elmenet list.public final BlobElementsUploadFileCreateElementResponse call(String did, String wid) throws OnshapeException
did - Document IDwid - Workspace IDOnshapeException - On HTTP or serialization errorpublic final BlobElementsUploadFileCreateElementResponse call(OnshapeDocument document) throws OnshapeException
document - Document object from Onshape URL.OnshapeException - On HTTP or serialization errorCopyright © 2021. All rights reserved.