OKMDashboard
Esta página aún no está disponible en tu idioma.
Basics
Section titled “Basics”On all methods you’ll see parameter named “token”. When accessing application across SOAP the login process returns a token, what is used to identify the user on all the exposed methods. From default application execution context you must use “null” value what indicates to the application must use the “user session”.
Methods
Section titled “Methods”getUserCheckedOutDocuments
Section titled “getUserCheckedOutDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserCheckedOutDocuments(String token) | List |
Get the list of documents checkout by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getUserCheckedOutDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastModifiedDocuments
Section titled “getUserLastModifiedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastModifiedDocuments(String token) | List |
Get the list of the last documents modified by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getUserLastModifiedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLockedDocuments
Section titled “getUserLockedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLockedDocuments(String token) | List |
Get the list of the locked documents modified by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getUserLockedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserSubscribedDocuments
Section titled “getUserSubscribedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserSubscribedDocuments(String token) | List |
Get the list of the subscribed documents by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getUserSubscribedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserSubscribedFolders
Section titled “getUserSubscribedFolders”Description:
| Method | Return values | Description |
|---|---|---|
| getUserSubscribedFolders(String token) | List |
Get the list of the subscribed folders by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardFolderResult;
public class Test { public static void main(String[] args) { try { for (DashboardFolderResult dashboardFolderResult : OKMDashboard.getInstance().getUserSubscribedFolders(null)) { System.out.println(dashboardFolderResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastUploadedDocuments
Section titled “getUserLastUploadedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastUploadedDocuments(String token) | List |
Get the list of the last uploaded documents by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getUserLastUploadedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastDownloadedDocuments
Section titled “getUserLastDownloadedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastDownloadedDocuments(String token) | List |
Get the list of the last download documents by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getUserLastDownloadedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastImportedMails
Section titled “getUserLastImportedMails”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastImportedMails(String token) | List |
Get the list of the last imported mails by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardMailResult;
public class Test { public static void main(String[] args) { try { for (DashboardMailResult dashboardMailResult : OKMDashboard.getInstance().getUserLastImportedMails(null)) { System.out.println(dashboardMailResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastImportedMailAttachments
Section titled “getUserLastImportedMailAttachments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastImportedMailAttachments(String token) | List |
Get the list of the last imported mail attachments by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getUserLastImportedMailAttachments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserDocumentsSize
Section titled “getUserDocumentsSize”Description:
| Method | Return values | Description |
|---|---|---|
| getUserDocumentsSize(String token) | long | Return the total size in bytes of the user documents. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.util.FormatUtil;
public class Test { public static void main(String[] args) { try { long sizeInBytes = OKMDashboard.getInstance().getUserDocumentsSize(null); System.out.println(FormatUtil.formatSize(sizeInBytes));
} catch (Exception e) { e.printStackTrace(); } }}getUserSearchs
Section titled “getUserSearchs”Description:
| Method | Return values | Description |
|---|---|---|
| getUserSearchs(String token) | List |
Get the list of all “user news” saved by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.dao.bean.QueryParams;
public class Test { public static void main(String[] args) { try { for (QueryParams qp : OKMDashboard.getInstance().getUserSearchs(null)) { System.out.println(qp); }
} catch (Exception e) { e.printStackTrace(); } }}Description:
| Method | Return values | Description |
|---|---|---|
| find(String token, int qpId) | List |
Execute a “user news”. |
- The param qpId is the unique identifier of the “users news” search.
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardNodeResult;import com.openkm.bean.Document;import com.openkm.bean.Folder;import com.openkm.bean.Mail;
public class Test { public static void main(String[] args) { try { int qpId = 12; for (DashboardNodeResult dashboardNodeResult : OKMDashboard.getInstance().find(null, qpId)) { if (dashboardNodeResult.getNode() instanceof Document ) { Document doc = (Document) dashboardNodeResult.getNode(); System.out.println(doc); } else if (dashboardNodeResult.getNode() instanceof Folder ) { Folder fld = (Folder) dashboardNodeResult.getNode(); System.out.println(fld); } else if (dashboardNodeResult.getNode() instanceof Mail ) { Mail mail = (Mail) dashboardNodeResult.getNode(); System.out.println(mail); } }
} catch (Exception e) { e.printStackTrace(); } }}getLastWeekTopDownloadedDocuments
Section titled “getLastWeekTopDownloadedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastWeekTopDownloadedDocuments(String token) | List |
Get the list of the top downloaded documents during the last week by all the users. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getLastWeekTopDownloadedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastMonthTopDownloadedDocuments
Section titled “getLastMonthTopDownloadedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastMonthTopDownloadedDocuments(String token) | List |
Get the list of the top downloaded documents during the last month by all the users. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getLastMonthTopDownloadedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastWeekTopModifiedDocuments
Section titled “getLastWeekTopModifiedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastWeekTopModifiedDocuments(String token) | List |
Get the list of the top modified documents during the last week by all the users. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getLastWeekTopModifiedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastMonthTopModifiedDocuments
Section titled “getLastMonthTopModifiedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastMonthTopModifiedDocuments(String token) | List |
Get the list of the top modified documents during the last month by all the users. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getLastMonthTopModifiedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastModifiedDocuments
Section titled “getLastModifiedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastModifiedDocuments(String token) | List |
Get the list of the last modified documents by all the users. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getLastModifiedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastUploadedDocuments
Section titled “getLastUploadedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastUploadedDocuments(String token) | List |
Get the list of the last uploaded documents by all the users. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardDocumentResult;
public class Test { public static void main(String[] args) { try { for (DashboardDocumentResult dashboardDocumentResult : OKMDashboard.getInstance().getLastUploadedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}visiteNode
Section titled “visiteNode”Description:
| Method | Return values | Description |
|---|---|---|
| visiteNode(String token, String source, String node, Calendar date) | void | Mark a node as a visited. |
- Available sources:
Example:
package com.openkm;
import java.util.Calendar;
import com.openkm.api.OKMDashboard;
public class Test { public static void main(String[] args) { try { Calendar cal = Calendar.getInstance(); OKMDashboard.getInstance().visiteNode(null, "LastWeekTopDownloadedDocuments", "/okm:root/sample.pdf", cal); } catch (Exception e) { e.printStackTrace(); } }}