@@ -316,46 +316,46 @@ public String copyItem(@NotNull String srcId, @NotNull String destId) throws Err
316316 public String copyItem (@ NotNull String srcId , @ NotNull String destId , @ NotNull String newName )
317317 throws ErrorResponseException {
318318 byte [] content = ("{\" parentReference\" :{\" id\" :\" " + destId + "\" },\" name\" :\" " + newName + "\" }" ).getBytes ();
319- return copyItem (ITEM_ID_PREFIX + srcId + "/action.copy" , content );
319+ return copyItem (ITEM_ID_PREFIX + srcId + "/" + COPY , content );
320320 }
321321
322322 @ NotNull
323323 public String copyItem (@ NotNull String srcId , @ NotNull PathPointer destPath ) throws ErrorResponseException {
324324 byte [] content = ("{\" parentReference\" :" + destPath .toJson () + "}" ).getBytes ();
325- return copyItem (ITEM_ID_PREFIX + srcId + "/action.copy" , content );
325+ return copyItem (ITEM_ID_PREFIX + srcId + "/" + COPY , content );
326326 }
327327
328328 @ NotNull
329329 public String copyItem (@ NotNull String srcId , @ NotNull PathPointer dest , @ NotNull String newName )
330330 throws ErrorResponseException {
331331 byte [] content = ("{\" parentReference\" :" + dest .toJson () + ",\" name\" :\" " + newName + "\" }" ).getBytes ();
332- return copyItem (ITEM_ID_PREFIX + srcId + "/action.copy" , content );
332+ return copyItem (ITEM_ID_PREFIX + srcId + "/" + COPY , content );
333333 }
334334
335335 @ NotNull
336336 public String copyItem (@ NotNull PathPointer srcPath , @ NotNull String destId ) throws ErrorResponseException {
337337 byte [] content = ("{\" parentReference\" :{\" id\" :\" " + destId + "\" }}" ).getBytes ();
338- return copyItem (srcPath .resolveOperator (Operator . ACTION_COPY ), content );
338+ return copyItem (srcPath .resolveOperator (COPY ), content );
339339 }
340340
341341 @ NotNull
342342 public String copyItem (@ NotNull PathPointer srcPath , @ NotNull String destId , @ NotNull String newName )
343343 throws ErrorResponseException {
344344 byte [] content = ("{\" parentReference\" :{\" id\" :\" " + destId + "\" },\" name\" :\" " + newName + "\" }" ).getBytes ();
345- return copyItem (srcPath .resolveOperator (Operator . ACTION_COPY ), content );
345+ return copyItem (srcPath .resolveOperator (COPY ), content );
346346 }
347347
348348 @ NotNull
349349 public String copyItem (@ NotNull BasePointer src , @ NotNull BasePointer dest ) throws ErrorResponseException {
350350 byte [] content = ("{\" parentReference\" :" + dest .toJson () + "}" ).getBytes ();
351- return copyItem (src .resolveOperator (Operator . ACTION_COPY ), content );
351+ return copyItem (src .resolveOperator (COPY ), content );
352352 }
353353
354354 @ NotNull
355355 public String copyItem (@ NotNull BasePointer src , @ NotNull BasePointer dest , @ NotNull String newName )
356356 throws ErrorResponseException {
357357 byte [] content = ("{\" parentReference\" :" + dest .toJson () + ",\" name\" :\" " + newName + "\" }" ).getBytes ();
358- return copyItem (src .resolveOperator (Operator . ACTION_COPY ), content );
358+ return copyItem (src .resolveOperator (COPY ), content );
359359 }
360360
361361
@@ -567,18 +567,18 @@ private DownloadFuture _downloadAsync(@NotNull String api, @NotNull Path downloa
567567 public UploadFuture uploadFile (@ NotNull String parentId , @ NotNull Path filePath ) {
568568 String fileName = filePath .getFileName ().toString ();
569569 return requestTool .upload (
570- ITEM_ID_PREFIX + parentId + ":/" + fileName + ":/" + UPLOAD_CREATE_SESSION , filePath );
570+ ITEM_ID_PREFIX + parentId + ":/" + fileName + ":/" + CREATE_UPLOAD_SESSION , filePath );
571571 }
572572
573573 public UploadFuture uploadFile (@ NotNull IdPointer parentId , @ NotNull Path filePath ) {
574574 String fileName = filePath .getFileName ().toString ();
575575 return requestTool .upload (
576- parentId .toASCIIApi () + ":/" + fileName + ":/" + UPLOAD_CREATE_SESSION , filePath );
576+ parentId .toASCIIApi () + ":/" + fileName + ":/" + CREATE_UPLOAD_SESSION , filePath );
577577 }
578578
579579 public UploadFuture uploadFile (@ NotNull PathPointer parentPath , @ NotNull Path filePath ) {
580580 String fileName = filePath .getFileName ().toString ();
581- return requestTool .upload (parentPath .resolve (fileName ).resolveOperator (UPLOAD_CREATE_SESSION ), filePath );
581+ return requestTool .upload (parentPath .resolve (fileName ).resolveOperator (CREATE_UPLOAD_SESSION ), filePath );
582582 }
583583
584584
0 commit comments