Package com.google.enterprise.connector.filenet4.filewrap

Examples of com.google.enterprise.connector.filenet4.filewrap.IDocument


  }

  private void testUnreleasedNextDocument(Map<IId, IBaseObject> entries,
      IId unreleasedGuid, SkipPosition expectedPosition) throws Exception {
    // Setup object store
    @SuppressWarnings("unchecked")
    MockObjectStore os =
        newObjectStore("MockObjectStore", DatabaseType.MSSQL, entries);

    // Begin testing nextDocument for exception
    DocumentList docList = getObjectUnderTest(os, getDocuments(os.getObjects()),
        getCustomDeletion(os.getObjects()), getDeletionEvents(os.getObjects()));

    SkipPosition actualPosition = SkipPosition.FIRST;
    try {
      for (Document doc = docList.nextDocument(); doc != null;
          doc = docList.nextDocument()) {
View Full Code Here


        { "CD000002-0000-0000-0000-000000000000", CHECKPOINT_TIMESTAMP },
        { "CD000003-0000-0000-0000-000000000000", CHECKPOINT_TIMESTAMP },
    };

    // Setup object store
    @SuppressWarnings("unchecked")
    MockObjectStore os = newObjectStore("MockObjectStore", DatabaseType.MSSQL,
        generateObjectMap(docEntries, false, true),
        generateObjectMap(deEntries, true, true),
        generateCustomDeletion(cdEntries, true));
    return os;
View Full Code Here

        generateCustomDeletion(cdEntries, true));
    return os;
  }

  public void testMockCheckpoint() throws Exception {
    MockObjectStore os = getCheckpointObjectStore();
    testMockCheckpoint(os, getDocuments(os.getObjects()),
        getCustomDeletion(os.getObjects()),
        getDeletionEvents(os.getObjects()));
  }
View Full Code Here

        getCustomDeletion(os.getObjects()),
        getDeletionEvents(os.getObjects()));
  }

  public void testMockCheckpoint_nullCustomDeletes() throws Exception {
    MockObjectStore os = getCheckpointObjectStore();
    testMockCheckpoint(os, getDocuments(os.getObjects()), null,
        getDeletionEvents(os.getObjects()));
  }
View Full Code Here

    testMockCheckpoint(os, getDocuments(os.getObjects()), null,
        getDeletionEvents(os.getObjects()));
  }

  public void testMockCheckpoint_emptyDocuments() throws Exception {
    MockObjectStore os = getCheckpointObjectStore();
    testMockCheckpoint(os, newEmptyObjectSet(),
        getCustomDeletion(os.getObjects()), getDeletionEvents(os.getObjects()));
  }
View Full Code Here

    testMockCheckpoint(os, newEmptyObjectSet(),
        getCustomDeletion(os.getObjects()), getDeletionEvents(os.getObjects()));
  }

  public void testMockCheckpoint_emptyCustomDeletes() throws Exception {
    MockObjectStore os = getCheckpointObjectStore();
    testMockCheckpoint(os, getDocuments(os.getObjects()),
        newEmptyObjectSet(), getDeletionEvents(os.getObjects()));
  }
View Full Code Here

    testMockCheckpoint(os, getDocuments(os.getObjects()),
        newEmptyObjectSet(), getDeletionEvents(os.getObjects()));
  }

  public void testMockCheckpoint_emptyDeletionEvents() throws Exception {
    MockObjectStore os = getCheckpointObjectStore();
    testMockCheckpoint(os, getDocuments(os.getObjects()),
        getCustomDeletion(os.getObjects()), newEmptyObjectSet());
  }
View Full Code Here

      Map<IId, IBaseObject>... objectMaps) {
    Map<IId, IBaseObject> data = new HashMap<IId, IBaseObject>();
    for (Map<IId, IBaseObject> objectMap : objectMaps) {
      data.putAll(objectMap);
    }
    return new MockObjectStore(name, dbType, data);
  }
View Full Code Here

    connector = TestObjectFactory.newFileConnector();
  }

  private DocumentList getDocumentList(String[][] entries,
      List<AccessPermission>... perms) throws Exception {
    MockObjectStore objectStore = getObjectStore(entries, perms);
    IObjectSet objectSet = getObjectSet(objectStore);
    assertNotNull(objectStore);
    assertEquals(entries.length, objectSet.getSize());
    return new FileDocumentList(objectSet, new EmptyObjectSet(),
        new EmptyObjectSet(), objectStore, connector, null);
View Full Code Here

        new EmptyObjectSet(), objectStore, connector, null);
  }

  private MockObjectStore getObjectStore(String[][] entries,
      List<AccessPermission>... perms) throws Exception {
    return new MockObjectStore("TestObjectStore", DatabaseType.MSSQL,
        getObjectMap(entries, perms));
  }
View Full Code Here

TOP

Related Classes of com.google.enterprise.connector.filenet4.filewrap.IDocument

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.