/** * Returns the type document entry from the resource id. If the resource id * id "document:12345", then "document" is returned. * * @return the document type * . */ public String getType() { String result = getResourceId(); if (result != null) { int position = result.lastIndexOf(":"); if (position > 0) { return result.substring(0, position); } } return result; }
/** * Returns the type document entry from the resource id. If the resource id * id "document:12345", then "document" is returned. * * @return the document type * . */ public String getType() { String result = getResourceId(); if (result != null) { int position = result.lastIndexOf(":"); if (position > 0) { return result.substring(0, position); } } return result; }
/** * Returns the type document entry from the resource id. If the resource id * id "document:12345", then "document" is returned. * * @return the document type * . */ public String getType() { String result = getResourceId(); if (result != null) { int position = result.lastIndexOf(":"); if (position > 0) { return result.substring(0, position); } } return result; }
/** * Gets the docId or spreadsheet key from the resource id. This is the id that * can be used to construct the export url or link to google docs. * * <code>http://docs.google.com/present/edit?id={id}</code> * <code>http://spreadsheets.google.com/ccc?key={id}</code> * * @return the Google Docs doc id * . */ public String getDocId() { String result = getResourceId(); if (result != null) { int position = result.lastIndexOf(":"); if (position > 0) { result = result.substring(position + 1); } } return result; }
/** * Gets the docId or spreadsheet key from the resource id. This is the id that * can be used to construct the export url or link to google docs. * * <code>http://docs.google.com/present/edit?id={id}</code> * <code>http://spreadsheets.google.com/ccc?key={id}</code> * * @return the Google Docs doc id * . */ public String getDocId() { String result = getResourceId(); if (result != null) { int position = result.lastIndexOf(":"); if (position > 0) { result = result.substring(position + 1); } } return result; }
/** * Gets the docId or spreadsheet key from the resource id. This is the id that * can be used to construct the export url or link to google docs. * * <code>http://docs.google.com/present/edit?id={id}</code> * <code>http://spreadsheets.google.com/ccc?key={id}</code> * * @return the Google Docs doc id * . */ public String getDocId() { String result = getResourceId(); if (result != null) { int position = result.lastIndexOf(":"); if (position > 0) { result = result.substring(position + 1); } } return result; }
resourceId = entry.getResourceId();