コード例 #1
0
  @Override
  protected JSONObject getJson() throws Exception {
    JSONObject attachmentDescription = attDescription.getJson();

    JSONObject originalFileDescription =
        attachmentDescription.optJSONObject(UploadConstants.ORIGINAL_FILE_KEY);

    return originalFileDescription;
  }
コード例 #2
0
  public File getMediaFile() throws Exception {
    File file = null;

    JSONObject originalObj = getJson();
    if (JSONSupport.containsKey(originalObj, UploadConstants.MEDIA_FILE_KEY)) {
      String mediaFileName = originalObj.optString(UploadConstants.MEDIA_FILE_KEY);
      file = new File(attDescription.getMediaDir(), mediaFileName);
    }

    return file;
  }
コード例 #3
0
 @Override
 protected void setSavingRequired(boolean flag) {
   attDescription.setSavingRequired(flag);
 }