All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ninja.WithControllerMethod Maven / Gradle / Ivy

/**
 * Copyright (C) the original author or authors.
 *
 * 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 ninja;

import ninja.ControllerMethods.ControllerMethod;
import ninja.ControllerMethods.ControllerMethod0;
import ninja.ControllerMethods.ControllerMethod1;
import ninja.ControllerMethods.ControllerMethod10;
import ninja.ControllerMethods.ControllerMethod2;
import ninja.ControllerMethods.ControllerMethod3;
import ninja.ControllerMethods.ControllerMethod4;
import ninja.ControllerMethods.ControllerMethod5;
import ninja.ControllerMethods.ControllerMethod6;
import ninja.ControllerMethods.ControllerMethod7;
import ninja.ControllerMethods.ControllerMethod8;
import ninja.ControllerMethods.ControllerMethod9;

/**
 * Interface that exposes multiple with methods that accept a large number of
 * various argument combinations.
 * @param  The result to return
 */
public interface WithControllerMethod {
    
    T with(ControllerMethod controllerMethod);
    
    default T with(ControllerMethod0 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod1 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod2 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod3 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod4 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod5 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod6 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod7 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod8 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod9 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
    default  T with(ControllerMethod10 controllerMethod) {
        return with((ControllerMethod)controllerMethod);
    }
    
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy