Package com.google.enterprise.connector.ldap.LdapSchemaFinder

Examples of com.google.enterprise.connector.ldap.LdapSchemaFinder.SchemaResult


    doBasicSchemaTest(ldapHandler);
  }

  private void doBasicSchemaTest(SimpleMockLdapHandler ldapHandler) {
    LdapSchemaFinder ldapSchemaFinder = new LdapSchemaFinder(ldapHandler);
    SchemaResult result = ldapSchemaFinder.find(100);
    Set<String> schema = Sets.newHashSet(result.getSchema().keySet());
    for (String schemaKey: ldapHandler.getSchemaKeys()) {
      assertTrue("Should find schema key: \"" + schemaKey + "\"",
          schema.remove(schemaKey));
    }
    assertEquals("some schema keys not found", 0, schema.size());
View Full Code Here


      validateNotNull(schemaFinder, "schemaFinder");
      if (configureResponse != null) {
        return;
      }

      SchemaResult schemaResult = schemaFinder.find(MAX_SCHEMA_RESULTS);
      validateNotNull(schemaResult, "schemaResult");
      //check if schema result fields are returned, display error of there are none
      if (schemaResult.getResultCount() <= 0) {
        configureResponse =
            new ConfigureResponse(bundle.getString(ErrorMessages.NO_RESULTS_FOR_GIVEN_SEARCH_STRING
                .name()), getFormRows(null));
      }
     
      if (configureResponse != null) {
        return;
      }

      Set<String> foundSchema = schemaResult.getSchema().keySet();
      validateNotNull(foundSchema, "foundSchema");
      if (configureResponse != null) {
        return;
      }
      schemaField.setKeys(foundSchema);
View Full Code Here

TOP

Related Classes of com.google.enterprise.connector.ldap.LdapSchemaFinder.SchemaResult

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.