/*
 * Copyright 2012 Shared Learning Collaborative, LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.slc.sli.api.security.context.validator;

import java.util.Set;

public interface IContextValidator {

    /**
     * Simple method that can return true if it knows how to validate who you are to the
     * type of entity asked for. Also is split up into transitive vs non-transitive access
     * 
     * Transitive means that your ability to see these things goes beyond direct association
     * and includes extra context through other means. (i.e. Transitive access to section is
     * through both your direct section associations and the sections of the students that a
     * teacher teaches)
     * 
     * @param entityType
     * @param isTransitive
     * @return
     */
    public abstract boolean canValidate(String entityType, boolean isTransitive);
    
    public abstract boolean validate(String entityType, Set<String> ids);
    
}

@@ -912,25 +912,24 @@
 ccess%0A     *
- 
 %0A     * Tran
@@ -1226,17 +1226,16 @@
 )%0A     *
- 
 %0A     * 
@@ -1263,42 +1263,203 @@
   * 
-@param isTransitive%0A     * @return
+           Type of entity being requested.%0A     * @param isTransitive%0A     *            Flag including transitive access to entity type.%0A     * @return True if access is allowed, false otherwise.
 %0A   
@@ -1545,20 +1545,457 @@
 itive);%0A
+%0A
     
+/**%0A     * Validates that the user has access to the set of entities of type 'entityType' with _id%0A     * contained within the specified 'ids' Set.%0A     *%0A     * @param entityType%0A     *            Type of entities being requested.%0A     * @param ids%0A     *            Set of Strings representing the _id's of entities being requested.%0A     * @return True if the user has access to ALL of the entities requested, false otherwise.%0A     */
 %0A    pub
@@ -2065,11 +2065,6 @@
 s);%0A
-    %0A
 %7D%0A

update javadoc for context validator interface