OKMDashboard
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(); } }}getUserLockedRecords
Section titled “getUserLockedRecords”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLockedRecords(String token) | List |
Get the list of the locked records by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardRecordResult;
public class Test { public static void main(String[] args) { try { for (DashboardRecordResult dashboardRecordResult : OKMDashboard.getInstance().getUserLockedRecords(null)) { System.out.println(dashboardRecordResult); } } 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(); } }}getUserSubscribedRecords
Section titled “getUserSubscribedRecords”Description:
| Method | Return values | Description |
|---|---|---|
| getUserSubscribedRecords(String token) | List |
Get the list of the subscribed records by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardRecordResult;
public class Test { public static void main(String[] args) { try { for (DashboardRecordResult dashboardRecordResult : OKMDashboard.getInstance().getUserSubscribedRecords(null)) { System.out.println(dashboardRecordResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastCreatedDocuments
Section titled “getUserLastCreatedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastCreatedDocuments(String token) | List |
Get the list of the last created 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().getUserLastCreatedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastCreatedFolders
Section titled “getUserLastCreatedFolders”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastCreatedFolders(String token) | List |
Get the list of the last created 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().getUserLastCreatedFolders(null)) { System.out.println(dashboardFolderResult); } } catch (Exception e) { e.printStackTrace(); } }}getUserLastCreatedRecords
Section titled “getUserLastCreatedRecords”Description:
| Method | Return values | Description |
|---|---|---|
| getUserLastCreatedRecords(String token) | List |
Get the list of the last created records by the user. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardRecordResult;
public class Test { public static void main(String[] args) { try { for (DashboardRecordResult dashboardRecordResult : OKMDashboard.getInstance().getUserLastCreatedRecords(null)) { System.out.println(dashboardRecordResult); } } 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;import com.openkm.bean.Record;
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 Record ) { Record rec = (Record) dashboardNodeResult.getNode(); System.out.println(rec); } 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(); } }}getLastCreatedDocuments
Section titled “getLastCreatedDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastCreatedDocuments(String token) | List |
Get the list of the last created 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().getLastCreatedDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastCheckedOutDocuments
Section titled “getLastCheckedOutDocuments”Description:
| Method | Return values | Description |
|---|---|---|
| getLastCheckedOutDocuments(String token) | List |
Get the list of the last documents on edition 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().getLastCheckedOutDocuments(null)) { System.out.println(dashboardDocumentResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastCreatedFolders
Section titled “getLastCreatedFolders”Description:
| Method | Return values | Description |
|---|---|---|
| getLastCreatedFolders(String token) | List |
Get the list of the last created folders by all the users. |
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().getLastCreatedFolders(null)) { System.out.println(dashboardFolderResult); } } catch (Exception e) { e.printStackTrace(); } }}getLastCreatedRecords
Section titled “getLastCreatedRecords”Description:
| Method | Return values | Description |
|---|---|---|
| getLastCreatedRecords(String token) | List |
Get the list of the last created records by all the users. |
Example:
package com.openkm;
import com.openkm.api.OKMDashboard;import com.openkm.bean.DashboardRecordResult;
public class Test { public static void main(String[] args) { try { for (DashboardRecordResult dashboardRecordResult : OKMDashboard.getInstance().getLastCreatedRecords(null)) { System.out.println(dashboardRecordResult); } } 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(); } }}