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

io.fabric8.kubernetes.api.model.KubernetesListFluent Maven / Gradle / Ivy

There is a newer version: 0.0.54
Show newest version
package io.fabric8.kubernetes.api.model;

import io.fabric8.openshift.api.model.BuildConfig;
import io.fabric8.openshift.api.model.OAuthClient;
import io.fabric8.openshift.api.model.DeploymentConfig;
import java.util.Map;
import io.fabric8.openshift.api.model.ImageStream;
import java.util.List;
import io.fabric8.openshift.api.model.template.Template;
import java.util.HashMap;
import io.fabric8.openshift.api.model.OAuthAccessToken;
import io.fabric8.openshift.api.model.OAuthClientAuthorization;
import io.fabric8.openshift.api.model.Route;
import java.util.ArrayList;
import io.fabric8.openshift.api.model.OAuthAccessTokenFluent;
import io.fabric8.common.Nested;
import io.fabric8.common.Builder;
import io.fabric8.common.Fluent;
import io.fabric8.openshift.api.model.template.TemplateBuilder;
import io.fabric8.openshift.api.model.ImageStreamBuilder;
import io.fabric8.openshift.api.model.RouteFluent;
import io.fabric8.openshift.api.model.DeploymentConfigBuilder;
import io.fabric8.openshift.api.model.BuildConfigFluent;
import io.fabric8.openshift.api.model.OAuthClientBuilder;
import io.fabric8.openshift.api.model.RouteBuilder;
import io.fabric8.openshift.api.model.OAuthAccessTokenBuilder;
import io.fabric8.openshift.api.model.BuildConfigBuilder;
import io.fabric8.openshift.api.model.OAuthClientFluent;
import io.fabric8.openshift.api.model.ImageStreamFluent;
import io.fabric8.openshift.api.model.OAuthClientAuthorizationFluent;
import io.fabric8.openshift.api.model.DeploymentConfigFluent;
import io.fabric8.openshift.api.model.OAuthClientAuthorizationBuilder;
import io.fabric8.openshift.api.model.template.TemplateFluent;

public class KubernetesListFluent> extends BaseKubernetesListFluent implements Fluent{

     List services = new ArrayList();     List replicationControllers = new ArrayList();     List pods = new ArrayList();     List buildConfigs = new ArrayList();     List deploymentConfigs = new ArrayList();     List imageStreams = new ArrayList();     List routes = new ArrayList();     List templates = new ArrayList();     List oAuthClients = new ArrayList();     List oAuthClientAuthorizations = new ArrayList();     List oAuthAccessTokens = new ArrayList();     List namespaces = new ArrayList();     List secrets = new ArrayList();

    public T addToServices( Service item){
    if (item != null) {ServiceBuilder builder = new ServiceBuilder(item);_visitables.add(builder);this.services.add(builder);} return (T)this;
    }
    public List getServices(){
    return build(services);
    }
    public T withServices( List services){
    this.services.clear();if (services != null) {for (Service item : services){this.addToServices(item);}} return (T) this;
    }
    public ServicesNested addNewService(){
    return new ServicesNested();
    }
    public T addToReplicationControllers( ReplicationController item){
    if (item != null) {ReplicationControllerBuilder builder = new ReplicationControllerBuilder(item);_visitables.add(builder);this.replicationControllers.add(builder);} return (T)this;
    }
    public List getReplicationControllers(){
    return build(replicationControllers);
    }
    public T withReplicationControllers( List replicationControllers){
    this.replicationControllers.clear();if (replicationControllers != null) {for (ReplicationController item : replicationControllers){this.addToReplicationControllers(item);}} return (T) this;
    }
    public ReplicationControllersNested addNewReplicationController(){
    return new ReplicationControllersNested();
    }
    public T addToPods( Pod item){
    if (item != null) {PodBuilder builder = new PodBuilder(item);_visitables.add(builder);this.pods.add(builder);} return (T)this;
    }
    public List getPods(){
    return build(pods);
    }
    public T withPods( List pods){
    this.pods.clear();if (pods != null) {for (Pod item : pods){this.addToPods(item);}} return (T) this;
    }
    public PodsNested addNewPod(){
    return new PodsNested();
    }
    public T addToBuildConfigs( BuildConfig item){
    if (item != null) {BuildConfigBuilder builder = new BuildConfigBuilder(item);_visitables.add(builder);this.buildConfigs.add(builder);} return (T)this;
    }
    public List getBuildConfigs(){
    return build(buildConfigs);
    }
    public T withBuildConfigs( List buildConfigs){
    this.buildConfigs.clear();if (buildConfigs != null) {for (BuildConfig item : buildConfigs){this.addToBuildConfigs(item);}} return (T) this;
    }
    public BuildConfigsNested addNewBuildConfig(){
    return new BuildConfigsNested();
    }
    public T addToDeploymentConfigs( DeploymentConfig item){
    if (item != null) {DeploymentConfigBuilder builder = new DeploymentConfigBuilder(item);_visitables.add(builder);this.deploymentConfigs.add(builder);} return (T)this;
    }
    public List getDeploymentConfigs(){
    return build(deploymentConfigs);
    }
    public T withDeploymentConfigs( List deploymentConfigs){
    this.deploymentConfigs.clear();if (deploymentConfigs != null) {for (DeploymentConfig item : deploymentConfigs){this.addToDeploymentConfigs(item);}} return (T) this;
    }
    public DeploymentConfigsNested addNewDeploymentConfig(){
    return new DeploymentConfigsNested();
    }
    public T addToImageStreams( ImageStream item){
    if (item != null) {ImageStreamBuilder builder = new ImageStreamBuilder(item);_visitables.add(builder);this.imageStreams.add(builder);} return (T)this;
    }
    public List getImageStreams(){
    return build(imageStreams);
    }
    public T withImageStreams( List imageStreams){
    this.imageStreams.clear();if (imageStreams != null) {for (ImageStream item : imageStreams){this.addToImageStreams(item);}} return (T) this;
    }
    public ImageStreamsNested addNewImageStream(){
    return new ImageStreamsNested();
    }
    public T addToRoutes( Route item){
    if (item != null) {RouteBuilder builder = new RouteBuilder(item);_visitables.add(builder);this.routes.add(builder);} return (T)this;
    }
    public List getRoutes(){
    return build(routes);
    }
    public T withRoutes( List routes){
    this.routes.clear();if (routes != null) {for (Route item : routes){this.addToRoutes(item);}} return (T) this;
    }
    public RoutesNested addNewRoute(){
    return new RoutesNested();
    }
    public T addToTemplates( Template item){
    if (item != null) {TemplateBuilder builder = new TemplateBuilder(item);_visitables.add(builder);this.templates.add(builder);} return (T)this;
    }
    public List