├── .automation ├── build-rpm.sh └── build-srpm.sh ├── .copr └── Makefile ├── .github ├── CODEOWNERS └── workflows │ └── build.yml ├── .gitignore ├── .settings └── org.eclipse.buildship.core.prefs ├── INSTALL ├── Makefile.am ├── README.md ├── autogen.sh ├── build.gradle ├── config.json ├── configure.ac ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── java-client-kubevirt.spec.in ├── kubevirt-swagger.json ├── m4 └── .keep ├── pom.xml ├── pom.xml.in ├── settings.gradle ├── src ├── main │ └── java │ │ ├── kubevirt │ │ ├── ApiCallback.java │ │ ├── ApiClient.java │ │ ├── ApiException.java │ │ ├── ApiResponse.java │ │ ├── Configuration.java │ │ ├── GzipRequestInterceptor.java │ │ ├── JSON.java │ │ ├── Pair.java │ │ ├── ProgressRequestBody.java │ │ ├── ProgressResponseBody.java │ │ ├── StringUtil.java │ │ ├── auth │ │ │ ├── ApiKeyAuth.java │ │ │ ├── Authentication.java │ │ │ ├── HttpBasicAuth.java │ │ │ ├── OAuth.java │ │ │ └── OAuthFlow.java │ │ └── io │ │ │ ├── K8sCniCncfIoV1Api.java │ │ │ ├── KubevirtApi.java │ │ │ ├── TypesUID.java │ │ │ ├── V1APIGroup.java │ │ │ ├── V1APIGroupList.java │ │ │ ├── V1APIResource.java │ │ │ ├── V1APIResourceList.java │ │ │ ├── V1Affinity.java │ │ │ ├── V1BIOS.java │ │ │ ├── V1Bootloader.java │ │ │ ├── V1CDRomTarget.java │ │ │ ├── V1CPU.java │ │ │ ├── V1CPUFeature.java │ │ │ ├── V1Chassis.java │ │ │ ├── V1Clock.java │ │ │ ├── V1ClockOffsetUTC.java │ │ │ ├── V1CloudInitConfigDriveSource.java │ │ │ ├── V1CloudInitNoCloudSource.java │ │ │ ├── V1ConfigMapVolumeSource.java │ │ │ ├── V1ContainerDiskSource.java │ │ │ ├── V1DHCPOptions.java │ │ │ ├── V1DHCPPrivateOptions.java │ │ │ ├── V1DataVolumeSource.java │ │ │ ├── V1DeleteOptions.java │ │ │ ├── V1Devices.java │ │ │ ├── V1Disk.java │ │ │ ├── V1DiskTarget.java │ │ │ ├── V1DomainSpec.java │ │ │ ├── V1EFI.java │ │ │ ├── V1EmptyDiskSource.java │ │ │ ├── V1EphemeralVolumeSource.java │ │ │ ├── V1FeatureAPIC.java │ │ │ ├── V1FeatureHyperv.java │ │ │ ├── V1FeatureSpinlocks.java │ │ │ ├── V1FeatureState.java │ │ │ ├── V1FeatureVendorID.java │ │ │ ├── V1Features.java │ │ │ ├── V1Firmware.java │ │ │ ├── V1FloppyTarget.java │ │ │ ├── V1GPU.java │ │ │ ├── V1GenieNetwork.java │ │ │ ├── V1GroupVersionForDiscovery.java │ │ │ ├── V1HPETTimer.java │ │ │ ├── V1HTTPGetAction.java │ │ │ ├── V1HTTPHeader.java │ │ │ ├── V1HostDisk.java │ │ │ ├── V1Hugepages.java │ │ │ ├── V1HypervTimer.java │ │ │ ├── V1I6300ESBWatchdog.java │ │ │ ├── V1Initializer.java │ │ │ ├── V1Initializers.java │ │ │ ├── V1Input.java │ │ │ ├── V1Interface.java │ │ │ ├── V1InterfaceBridge.java │ │ │ ├── V1InterfaceMasquerade.java │ │ │ ├── V1InterfaceSRIOV.java │ │ │ ├── V1InterfaceSlirp.java │ │ │ ├── V1KVMTimer.java │ │ │ ├── V1LabelSelector.java │ │ │ ├── V1LabelSelectorRequirement.java │ │ │ ├── V1LocalObjectReference.java │ │ │ ├── V1LunTarget.java │ │ │ ├── V1Machine.java │ │ │ ├── V1Memory.java │ │ │ ├── V1MultusNetwork.java │ │ │ ├── V1Network.java │ │ │ ├── V1NetworkAttachmentDefinition.java │ │ │ ├── V1NetworkAttachmentDefinitionList.java │ │ │ ├── V1NetworkAttachmentDefinitionSpec.java │ │ │ ├── V1NodeAffinity.java │ │ │ ├── V1NodeSelector.java │ │ │ ├── V1NodeSelectorRequirement.java │ │ │ ├── V1NodeSelectorTerm.java │ │ │ ├── V1PITTimer.java │ │ │ ├── V1Patch.java │ │ │ ├── V1PersistentVolumeClaimSpec.java │ │ │ ├── V1PersistentVolumeClaimVolumeSource.java │ │ │ ├── V1PodAffinity.java │ │ │ ├── V1PodAffinityTerm.java │ │ │ ├── V1PodAntiAffinity.java │ │ │ ├── V1PodDNSConfig.java │ │ │ ├── V1PodDNSConfigOption.java │ │ │ ├── V1PodNetwork.java │ │ │ ├── V1Port.java │ │ │ ├── V1Preconditions.java │ │ │ ├── V1PreferredSchedulingTerm.java │ │ │ ├── V1Probe.java │ │ │ ├── V1RTCTimer.java │ │ │ ├── V1ResourceRequirements.java │ │ │ ├── V1Rng.java │ │ │ ├── V1RootPaths.java │ │ │ ├── V1SecretVolumeSource.java │ │ │ ├── V1ServerAddressByClientCIDR.java │ │ │ ├── V1ServiceAccountVolumeSource.java │ │ │ ├── V1Status.java │ │ │ ├── V1StatusCause.java │ │ │ ├── V1StatusDetails.java │ │ │ ├── V1TCPSocketAction.java │ │ │ ├── V1Timer.java │ │ │ ├── V1Toleration.java │ │ │ ├── V1TypedLocalObjectReference.java │ │ │ ├── V1VirtualMachine.java │ │ │ ├── V1VirtualMachineCondition.java │ │ │ ├── V1VirtualMachineInstance.java │ │ │ ├── V1VirtualMachineInstanceCondition.java │ │ │ ├── V1VirtualMachineInstanceGuestOSInfo.java │ │ │ ├── V1VirtualMachineInstanceList.java │ │ │ ├── V1VirtualMachineInstanceMigration.java │ │ │ ├── V1VirtualMachineInstanceMigrationCondition.java │ │ │ ├── V1VirtualMachineInstanceMigrationList.java │ │ │ ├── V1VirtualMachineInstanceMigrationSpec.java │ │ │ ├── V1VirtualMachineInstanceMigrationState.java │ │ │ ├── V1VirtualMachineInstanceMigrationStatus.java │ │ │ ├── V1VirtualMachineInstanceNetworkInterface.java │ │ │ ├── V1VirtualMachineInstancePreset.java │ │ │ ├── V1VirtualMachineInstancePresetList.java │ │ │ ├── V1VirtualMachineInstancePresetSpec.java │ │ │ ├── V1VirtualMachineInstanceReplicaSet.java │ │ │ ├── V1VirtualMachineInstanceReplicaSetCondition.java │ │ │ ├── V1VirtualMachineInstanceReplicaSetList.java │ │ │ ├── V1VirtualMachineInstanceReplicaSetSpec.java │ │ │ ├── V1VirtualMachineInstanceReplicaSetStatus.java │ │ │ ├── V1VirtualMachineInstanceSpec.java │ │ │ ├── V1VirtualMachineInstanceStatus.java │ │ │ ├── V1VirtualMachineInstanceTemplateSpec.java │ │ │ ├── V1VirtualMachineList.java │ │ │ ├── V1VirtualMachineSpec.java │ │ │ ├── V1VirtualMachineStateChangeRequest.java │ │ │ ├── V1VirtualMachineStatus.java │ │ │ ├── V1Volume.java │ │ │ ├── V1WatchEvent.java │ │ │ ├── V1Watchdog.java │ │ │ ├── V1WeightedPodAffinityTerm.java │ │ │ ├── V1alpha1DataVolume.java │ │ │ ├── V1alpha1DataVolumeBlankImage.java │ │ │ ├── V1alpha1DataVolumeSource.java │ │ │ ├── V1alpha1DataVolumeSourceHTTP.java │ │ │ ├── V1alpha1DataVolumeSourcePVC.java │ │ │ ├── V1alpha1DataVolumeSourceRegistry.java │ │ │ ├── V1alpha1DataVolumeSourceS3.java │ │ │ ├── V1alpha1DataVolumeSourceUpload.java │ │ │ ├── V1alpha1DataVolumeSpec.java │ │ │ └── V1alpha1DataVolumeStatus.java │ │ └── openshift │ │ └── io │ │ ├── OpenshiftApi.java │ │ ├── V1Route.java │ │ ├── V1RouteList.java │ │ ├── V1RoutePort.java │ │ ├── V1RouteSpec.java │ │ ├── V1Template.java │ │ └── V1TemplateList.java └── test │ └── java │ └── test │ ├── Main.java │ ├── Nodes.java │ ├── Routes.java │ ├── Templates.java │ └── VirtualMachines.java └── swagger-codegen-cli-2.4.9.jar /.automation/build-rpm.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -xe 2 | 3 | source $(dirname "$(readlink -f "$0")")/build-srpm.sh 4 | 5 | # Install build dependencies 6 | dnf builddep -y rpmbuild/SRPMS/*src.rpm 7 | 8 | # Build binary package 9 | rpmbuild \ 10 | --define "_topmdir rpmbuild" \ 11 | --define "_rpmdir rpmbuild" \ 12 | --rebuild rpmbuild/SRPMS/*src.rpm 13 | 14 | # Move RPMs to exported artifacts 15 | [[ -d $ARTIFACTS_DIR ]] || mkdir -p $ARTIFACTS_DIR 16 | find rpmbuild -iname \*rpm | xargs mv -t $ARTIFACTS_DIR 17 | -------------------------------------------------------------------------------- /.automation/build-srpm.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -xe 2 | 3 | # Directory, where build artifacts will be stored, should be passed as the 1st parameter 4 | ARTIFACTS_DIR=${1:-exported-artifacts} 5 | 6 | # Prepare source archive 7 | [[ -d rpmbuild/SOURCES ]] || mkdir -p rpmbuild/SOURCES 8 | 9 | ./autogen.sh --system 10 | ./configure 11 | 12 | # clean 13 | rm -rf rpmbuild/SOURCES/* 14 | make clean 15 | 16 | # build tarballs 17 | make dist 18 | 19 | # Build SRPMs 20 | rpmbuild \ 21 | -D "_topdir rpmbuild" \ 22 | -ts ./*.tar.gz 23 | -------------------------------------------------------------------------------- /.copr/Makefile: -------------------------------------------------------------------------------- 1 | .PHONY: installdeps srpm git-safe 2 | 3 | installdeps: 4 | dnf install -y \ 5 | autoconf \ 6 | automake \ 7 | createrepo_c \ 8 | dnf-utils \ 9 | findutils \ 10 | gcc \ 11 | git \ 12 | java-11-openjdk-devel \ 13 | make \ 14 | maven-source-plugin \ 15 | maven-shade-plugin \ 16 | maven \ 17 | rpm-build \ 18 | sed 19 | 20 | 21 | # explicity mark the copr generated git repo directory (which is done prior to the mock 22 | # call to the make_srpm and will be the current pwd) as safe for git commands 23 | git-safe: 24 | git config --global --add safe.directory "$(shell pwd)" 25 | 26 | srpm: installdeps git-safe 27 | $(eval SUFFIX=$(shell sh -c " echo '.$$(date -u +%Y%m%d%H%M%S).git$$(git rev-parse --short HEAD)'")) 28 | # changing the spec file as passing -D won't preserve the suffix when rebuilding in mock 29 | #sed "s:%{?release_suffix}:${SUFFIX}:" -i java-client-kubevirt.spec.in 30 | 31 | .automation/build-srpm.sh 32 | cp rpmbuild/SRPMS/$(shell sh -c "basename '$(spec)'|cut -f1 -d.")*.src.rpm $(outdir) 33 | -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | # https://help.github.com/en/articles/about-code-owners 2 | # Default reviewers for everything 3 | * @arso @mwperina 4 | -------------------------------------------------------------------------------- /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: build 2 | on: 3 | push: 4 | branches: [master] 5 | pull_request: 6 | branches: [master] 7 | workflow_dispatch: 8 | branches: [master] 9 | 10 | jobs: 11 | build: 12 | runs-on: ubuntu-latest 13 | strategy: 14 | fail-fast: false 15 | matrix: 16 | include: 17 | - name: centos-stream-8 18 | shortcut: cs8 19 | container-name: el8stream 20 | - name: centos-stream-9 21 | shortcut: cs9 22 | container-name: el9stream 23 | 24 | name: ${{ matrix.name }} 25 | 26 | env: 27 | ARTIFACTS_DIR: exported-artifacts 28 | 29 | container: 30 | image: quay.io/ovirt/buildcontainer:${{ matrix.container-name }} 31 | 32 | steps: 33 | - name: Checkout sources 34 | uses: ovirt/checkout-action@main 35 | 36 | - name: Perform build 37 | run: | 38 | .automation/build-rpm.sh $ARTIFACTS_DIR 39 | 40 | - name: Upload artifacts 41 | uses: ovirt/upload-rpms-action@v2 42 | with: 43 | directory: exported-artifacts/ 44 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Ignore Gradle project-specific cache directory 2 | .gradle 3 | 4 | # Intellij IDEA project files 5 | .idea/ 6 | *.iml 7 | *.ipr 8 | 9 | # Ignore Gradle build output directory 10 | build 11 | 12 | /bin/ 13 | _out 14 | /target/ 15 | /aclocal.m4 16 | /compile 17 | /configure 18 | /install-sh 19 | /autom4te.cache/ 20 | /Makefile 21 | /Makefile.in 22 | /config.log 23 | /config.status 24 | /java-client-kubevirt.spec 25 | /missing 26 | rpmbuild 27 | 28 | # Distribution tarballs 29 | *.tar.gz 30 | -------------------------------------------------------------------------------- /.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- 1 | connection.project.dir= 2 | eclipse.preferences.version=1 3 | -------------------------------------------------------------------------------- /INSTALL: -------------------------------------------------------------------------------- 1 | java-client-kubevirt 2 | ============================= 3 | 4 | Pacakge is standard autotool package. 5 | 6 | To build from source: 7 | 8 | $ autoreconf -ivf 9 | $ ./configure 10 | $ make 11 | $ make install 12 | 13 | plain j2se build and maven build (--with-maven). 14 | 15 | Java SDK is not installed, it is available for distribution specific 16 | installation at $(builddir)/target. 17 | 18 | Signing maven artifact is possible using the following environment 19 | variable: 20 | MAVEN_OPTS="-DperformRelease=true -Dgpg.keyname=C223E417 -Dgpg.passphrase=pass" 21 | 22 | Maven publish is done via oss.sonatype.org. 23 | -------------------------------------------------------------------------------- /Makefile.am: -------------------------------------------------------------------------------- 1 | # 2 | # java-client-kubevirt 3 | # Copyright (C) 2019 Red Hat, Inc. 4 | # 5 | # This library is free software; you can redistribute it and/or 6 | # modify it under the terms of the GNU Lesser General Public 7 | # License as published by the Free Software Foundation; either 8 | # version 2.1 of the License, or (at your option) any later version. 9 | # 10 | # This library is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | # Lesser General Public License for more details. 14 | # 15 | # You should have received a copy of the GNU Lesser General Public 16 | # License along with this library; if not, write to the Free Software 17 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 18 | # 19 | 20 | AUTOMAKE_OPTIONS = foreign 1.9 21 | ACLOCAL_AMFLAGS = -I m4 22 | 23 | MAINTAINERCLEANFILES = \ 24 | config.log config.status \ 25 | $(srcdir)/Makefile.in \ 26 | $(srcdir)/configure \ 27 | $(srcdir)/install-sh $(srcdir)/missing \ 28 | $(srcdir)/depcomp $(srcdir)/py-compile \ 29 | $(srcdir)/config.guess $(srcdir)/config.sub \ 30 | $(srcdir)/config.rpath \ 31 | $(srcdir)/ABOUT-NLS \ 32 | $(srcdir)/aclocal.m4 \ 33 | $(srcdir)/ln-sr \ 34 | $(NULL) 35 | 36 | EXTRA_DIST = \ 37 | $(srcdir)/pom.xml \ 38 | .gitignore \ 39 | $(NULL) 40 | 41 | dist_noinst_DATA = \ 42 | java-client-kubevirt.spec \ 43 | src \ 44 | $(NULL) 45 | 46 | clean-local: 47 | rm -fr target 48 | $(MVN) clean 49 | 50 | all-local: 51 | $(MVN) -X dependency:resolve 52 | 53 | all-local: dist 54 | 55 | 56 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Kubevirt java client (java-client-kubevirt) for oVirt 2 | 3 | [![Copr build status](https://copr.fedorainfracloud.org/coprs/ovirt/ovirt-master-snapshot/package/java-client-kubevirt/status_image/last_build.png)](https://copr.fedorainfracloud.org/coprs/ovirt/ovirt-master-snapshot/package/java-client-kubevirt/) 4 | 5 | Welcome to the Kubevirt Java client (java-client-kubevirt) for oVirt source repository. 6 | 7 | This repository is hosted on [gerrit.ovirt.org:java-client-kubevirt](https://gerrit.ovirt.org/#/admin/projects/java-client-kubevirt) 8 | and a **backup** of it is hosted on [GitHub:java-client-kubevirt](https://github.com/oVirt/java-client-kubevirt) 9 | 10 | 11 | ## How to contribute 12 | 13 | ### Submitting patches 14 | 15 | Patches are welcome! 16 | 17 | Please submit patches to [gerrit.ovirt.org:java-client-kubevirt](https://gerrit.ovirt.org/#/admin/projects/java-client-kubevirt). 18 | If you are not familiar with the review process for Gerrit patches you can read about [Working with oVirt Gerrit](https://ovirt.org/develop/dev-process/working-with-gerrit.html) 19 | on the [oVirt](https://ovirt.org/) website. 20 | 21 | **NOTE**: We might not notice pull requests that you create on Github, because we only use Github for backups. 22 | 23 | 24 | ### Found a bug or documentation issue? 25 | To submit a bug or suggest an enhancement for Kubevirt java client (java-client-kubevirt) for oVirt please use 26 | [oVirt Bugzilla java-client-kubevirt component for ovirt-distribution product](https://bugzilla.redhat.com/enter_bug.cgi?product=ovirt-distribution). 27 | 28 | If you find a documentation issue on the oVirt website please navigate and click "Report an issue on GitHub" in the page footer. 29 | 30 | 31 | ## Still need help? 32 | If you have any other questions, please join [oVirt Users forum / mailing list](https://lists.ovirt.org/admin/lists/users.ovirt.org/) and ask there. 33 | 34 | ## How to build 35 | 36 | build shadow jar: 37 | ``` 38 | ./gradlew shadowJar 39 | ``` 40 | 41 | publish to mavem local: 42 | ``` 43 | ./gradlew uploadShadow 44 | ``` 45 | 46 | generate kubevirt sources (model + api): 47 | 48 | ```bash 49 | java -jar swagger-codegen-cli-2.4.9.jar generate -i kubevirt-swagger.json -c config.json -l java -o _out 50 | ``` 51 | -------------------------------------------------------------------------------- /autogen.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | autoreconf -ivf 4 | -------------------------------------------------------------------------------- /build.gradle: -------------------------------------------------------------------------------- 1 | /* 2 | * This file was generated by the Gradle 'init' task. 3 | * 4 | * This generated file contains a sample Java Library project to get you started. 5 | * For more details take a look at the Java Libraries chapter in the Gradle 6 | * User Manual available at https://docs.gradle.org/5.6.2/userguide/java_library_plugin.html 7 | */ 8 | 9 | plugins { 10 | // Apply the java-library plugin to add support for Java Library 11 | id 'java-library' 12 | id 'com.github.johnrengelman.shadow' version '5.1.0' 13 | id 'maven-publish' 14 | } 15 | 16 | group = "org.ovirt.java-client-kubevirt" 17 | version = "0.0.12" 18 | 19 | shadowJar { 20 | classifier = null 21 | dependencies { 22 | exclude(dependency { 23 | it.moduleGroup == 'io.sundr' 24 | it.moduleGroup == 'org.bouncycastle' 25 | }) 26 | } 27 | } 28 | 29 | 30 | uploadShadow { 31 | repositories { 32 | mavenLocal() 33 | } 34 | } 35 | 36 | repositories { 37 | // Use jcenter for resolving dependencies. 38 | // You can declare any Maven/Ivy/file repository here. 39 | mavenLocal() 40 | jcenter() 41 | } 42 | 43 | dependencies { 44 | compile 'io.kubernetes:client-java:6.0.1' 45 | compile 'javax.annotation:javax.annotation-api:1.3.2' 46 | compile 'io.gsonfire:gson-fire:1.8.3' 47 | 48 | // Use JUnit test framework 49 | testImplementation 'junit:junit:4.12' 50 | } 51 | 52 | 53 | -------------------------------------------------------------------------------- /config.json: -------------------------------------------------------------------------------- 1 | { 2 | "modelPackage": "kubevirt.io", 3 | "apiPackage": "kubevirt.io", 4 | "groupId": "io.kubevirt", 5 | "artifactId": "client-java", 6 | "dateLibrary": "java8" 7 | } 8 | -------------------------------------------------------------------------------- /configure.ac: -------------------------------------------------------------------------------- 1 | dnl 2 | dnl Copyright (C) 2019 Red Hat, Inc. 3 | dnl 4 | dnl This library is free software; you can redistribute it and/or 5 | dnl modify it under the terms of the GNU Lesser General Public 6 | dnl License as published by the Free Software Foundation; either 7 | dnl version 2.1 of the License, or (at your option) any later version. 8 | dnl 9 | dnl This library is distributed in the hope that it will be useful, 10 | dnl but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 | dnl Lesser General Public License for more details. 13 | dnl 14 | dnl You should have received a copy of the GNU Lesser General Public 15 | dnl License along with this library; if not, write to the Free Software 16 | dnl Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 17 | dnl 18 | 19 | AC_PREREQ(2.60) 20 | 21 | define([VERSION_MAJOR], [0]) 22 | define([VERSION_MINOR], [5]) 23 | define([VERSION_FIX], [0]) 24 | define([VERSION_NUMBER], VERSION_MAJOR[.]VERSION_MINOR[.]VERSION_FIX) 25 | define([VERSION_SUFFIX], []) 26 | 27 | AC_INIT([java-client-kubevirt], VERSION_NUMBER[]VERSION_SUFFIX) 28 | PACKAGE_RPM_VERSION="VERSION_NUMBER" 29 | PACKAGE_RPM_RELEASE="2" 30 | PACKAGE_MAVEN_VERSION="VERSION_MAJOR.VERSION_MINOR.VERSION_FIX" 31 | AC_SUBST([PACKAGE_RPM_VERSION]) 32 | AC_SUBST([PACKAGE_RPM_RELEASE]) 33 | AC_SUBST([PACKAGE_MAVEN_VERSION]) 34 | 35 | AC_CONFIG_AUX_DIR([.]) 36 | AC_CONFIG_SRCDIR([Makefile.am]) 37 | AC_CONFIG_MACRO_DIR([m4]) 38 | AC_USE_SYSTEM_EXTENSIONS 39 | AM_INIT_AUTOMAKE([tar-pax]) 40 | 41 | AC_ARG_WITH( 42 | [maven-version-snapshot], 43 | [AS_HELP_STRING([--with-maven-version-snapshot], [maven version snapshot @<:@default=no@:>@])], 44 | , 45 | [with_maven_version_snapshot="no"] 46 | ) 47 | 48 | AC_ARG_WITH( 49 | [dist_only], 50 | [AS_HELP_STRING([--with-dist-only], [configure to enable source only distribution (e.g. make dist) @<:@default=no@:>@])], 51 | [with_dist_only="no"], 52 | ) 53 | 54 | AC_PROG_INSTALL 55 | AC_PROG_SED 56 | AC_PROG_MAKE_SET 57 | AC_PROG_MKDIR_P 58 | 59 | if test ! "${with_dist_only}" = "yes"; then 60 | AC_ARG_VAR([MVN], [path to mvn utility]) 61 | AC_CHECK_PROGS([MVN], [mvn]) 62 | 63 | test -z "${MVN}" && \ 64 | AC_MSG_ERROR([maven is required but not found]) 65 | fi 66 | 67 | if test "${with_maven_version_snapshot}" = "no"; then 68 | MAVEN_VERSION_SNAPSHOT="" 69 | else 70 | MAVEN_VERSION_SNAPSHOT="-SNAPSHOT" 71 | fi 72 | AC_SUBST([MAVEN_VERSION_SNAPSHOT]) 73 | 74 | AM_CONDITIONAL([WITH_DIST_ONLY], [test "${with_dist_only}" = "yes"]) 75 | 76 | AC_CONFIG_FILES([ 77 | Makefile 78 | pom.xml 79 | java-client-kubevirt.spec 80 | ]) 81 | AC_OUTPUT 82 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/oVirt/java-client-kubevirt/2cd69335f3167b6c8a89fc412f78aa97e366facb/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-bin.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /gradlew.bat: -------------------------------------------------------------------------------- 1 | @rem 2 | @rem Copyright 2015 the original author or authors. 3 | @rem 4 | @rem Licensed under the Apache License, Version 2.0 (the "License"); 5 | @rem you may not use this file except in compliance with the License. 6 | @rem You may obtain a copy of the License at 7 | @rem 8 | @rem https://www.apache.org/licenses/LICENSE-2.0 9 | @rem 10 | @rem Unless required by applicable law or agreed to in writing, software 11 | @rem distributed under the License is distributed on an "AS IS" BASIS, 12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | @rem See the License for the specific language governing permissions and 14 | @rem limitations under the License. 15 | @rem 16 | 17 | @if "%DEBUG%" == "" @echo off 18 | @rem ########################################################################## 19 | @rem 20 | @rem Gradle startup script for Windows 21 | @rem 22 | @rem ########################################################################## 23 | 24 | @rem Set local scope for the variables with windows NT shell 25 | if "%OS%"=="Windows_NT" setlocal 26 | 27 | set DIRNAME=%~dp0 28 | if "%DIRNAME%" == "" set DIRNAME=. 29 | set APP_BASE_NAME=%~n0 30 | set APP_HOME=%DIRNAME% 31 | 32 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 33 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" 34 | 35 | @rem Find java.exe 36 | if defined JAVA_HOME goto findJavaFromJavaHome 37 | 38 | set JAVA_EXE=java.exe 39 | %JAVA_EXE% -version >NUL 2>&1 40 | if "%ERRORLEVEL%" == "0" goto init 41 | 42 | echo. 43 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 44 | echo. 45 | echo Please set the JAVA_HOME variable in your environment to match the 46 | echo location of your Java installation. 47 | 48 | goto fail 49 | 50 | :findJavaFromJavaHome 51 | set JAVA_HOME=%JAVA_HOME:"=% 52 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 53 | 54 | if exist "%JAVA_EXE%" goto init 55 | 56 | echo. 57 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 58 | echo. 59 | echo Please set the JAVA_HOME variable in your environment to match the 60 | echo location of your Java installation. 61 | 62 | goto fail 63 | 64 | :init 65 | @rem Get command-line arguments, handling Windows variants 66 | 67 | if not "%OS%" == "Windows_NT" goto win9xME_args 68 | 69 | :win9xME_args 70 | @rem Slurp the command line arguments. 71 | set CMD_LINE_ARGS= 72 | set _SKIP=2 73 | 74 | :win9xME_args_slurp 75 | if "x%~1" == "x" goto execute 76 | 77 | set CMD_LINE_ARGS=%* 78 | 79 | :execute 80 | @rem Setup the command line 81 | 82 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 83 | 84 | @rem Execute Gradle 85 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 86 | 87 | :end 88 | @rem End local scope for the variables with windows NT shell 89 | if "%ERRORLEVEL%"=="0" goto mainEnd 90 | 91 | :fail 92 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 93 | rem the _cmd.exe /c_ return code! 94 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 95 | exit /b 1 96 | 97 | :mainEnd 98 | if "%OS%"=="Windows_NT" endlocal 99 | 100 | :omega 101 | -------------------------------------------------------------------------------- /java-client-kubevirt.spec.in: -------------------------------------------------------------------------------- 1 | # 2 | # java-client-kubevirt 3 | # Copyright (C) 2019 Red Hat, Inc. 4 | # 5 | # This library is free software; you can redistribute it and/or 6 | # modify it under the terms of the GNU Lesser General Public 7 | # License as published by the Free Software Foundation; either 8 | # version 2.1 of the License, or (at your option) any later version. 9 | # 10 | # This library is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | # Lesser General Public License for more details. 14 | # 15 | # You should have received a copy of the GNU Lesser General Public 16 | # License along with this library; if not, write to the Free Software 17 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 18 | # 19 | 20 | %global package_version @PACKAGE_VERSION@ 21 | %global package_maven_version @PACKAGE_MAVEN_VERSION@ 22 | 23 | %global _java_jdk_home /usr/lib/jvm/java-11-openjdk 24 | 25 | Summary: Kubevirt java client (%{name}) for oVirt 26 | Name: @PACKAGE_NAME@ 27 | Version: @PACKAGE_RPM_VERSION@ 28 | Release: @PACKAGE_RPM_RELEASE@%{?release_suffix}%{?dist} 29 | License: LGPLv2+ 30 | URL: http://www.ovirt.org 31 | Source: http://resources.ovirt.org/pub/ovirt-master-snapshot/src/%{name}/%{name}-%{package_version}.tar.gz 32 | Group: Development/Libraries 33 | 34 | BuildArch: noarch 35 | 36 | BuildRequires: gcc 37 | BuildRequires: java-11-openjdk-devel >= 11.0.4 38 | 39 | 40 | BuildRequires: javapackages-local 41 | BuildRequires: maven >= 3.5.0 42 | BuildRequires: maven-local 43 | BuildRequires: maven-dependency-plugin 44 | BuildRequires: maven-shade-plugin 45 | BuildRequires: maven-source-plugin 46 | BuildRequires: maven-compiler-plugin 47 | BuildRequires: maven-clean-plugin 48 | BuildRequires: maven-install-plugin 49 | # A few depencies are not yet packaged. Allowing xmvn to fetch them 50 | BuildRequires: maven-wagon-http 51 | BuildRequires: maven-resolver-connector-basic 52 | BuildRequires: maven-resolver-transport-wagon 53 | 54 | # All are provided by our fat jar 55 | Provides: mvn(io.kubernetes:client-java) = 6.0.1 56 | Provides: mvn(io.gsonfire:gson-fire) = 1.8.3 57 | Provides: mvn(javax.annotation:javax.annotation-api) = 1.3.2 58 | 59 | %description 60 | java client kubevirt 61 | 62 | %package javadoc 63 | Summary: Java-docs for %{name} 64 | Group: Documentation 65 | 66 | %description javadoc 67 | This package contains the API documentation for %{name}. 68 | 69 | %prep 70 | %setup -q -n %{name}-%{package_version} 71 | %if 0%{?rhel} > 7 72 | # No need for maven-javadoc-plugin in RHEL 8, xmvn will take care of it. 73 | %pom_remove_plugin -r :maven-javadoc-plugin pom.xml.in 74 | %endif 75 | 76 | %build 77 | %configure MVN="xmvn" 78 | # Force using OpenJDK 11 79 | export JAVA_HOME="%{_java_jdk_home}" 80 | 81 | # this step is necessary to resolve mvn dependencies that are not available 82 | # as RPM distribution 83 | make %{?_smp_mflags} 84 | 85 | %mvn_build -i -X -d -- %{?_mvn_opts} 86 | %mvn_artifact dependency-reduced-pom.xml target/@PACKAGE_NAME@-%{version}.jar 87 | 88 | %install 89 | %mvn_install 90 | 91 | %files -f .mfiles 92 | %dir %{_javadir}/%{name} 93 | 94 | %files javadoc -f .mfiles-javadoc 95 | 96 | %changelog 97 | * Mon Mar 30 2020 Piotr Kliczewski - 0.3.0 105 | - Add support for network attachment definitions 106 | 107 | * Thu Jan 23 2020 Piotr Kliczewski - 0.2.0 108 | - use brew maven-build 109 | 110 | * Mon Dec 2 2019 Piotr Kliczewski - 0.1.0 111 | - Initial changes 112 | -------------------------------------------------------------------------------- /m4/.keep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/oVirt/java-client-kubevirt/2cd69335f3167b6c8a89fc412f78aa97e366facb/m4/.keep -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | /* 2 | * This file was generated by the Gradle 'init' task. 3 | * 4 | * The settings file is used to specify which projects to include in your build. 5 | * 6 | * Detailed information about configuring a multi-project build in Gradle can be found 7 | * in the user manual at https://docs.gradle.org/5.6.2/userguide/multi_project_builds.html 8 | */ 9 | 10 | rootProject.name = 'client-java' 11 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/ApiCallback.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | import java.io.IOException; 17 | 18 | import java.util.Map; 19 | import java.util.List; 20 | 21 | /** 22 | * Callback for asynchronous API call. 23 | * 24 | * @param The return type 25 | */ 26 | public interface ApiCallback { 27 | /** 28 | * This is called when the API call fails. 29 | * 30 | * @param e The exception causing the failure 31 | * @param statusCode Status code of the response if available, otherwise it would be 0 32 | * @param responseHeaders Headers of the response if available, otherwise it would be null 33 | */ 34 | void onFailure(ApiException e, int statusCode, Map> responseHeaders); 35 | 36 | /** 37 | * This is called when the API call succeeded. 38 | * 39 | * @param result The result deserialized from response 40 | * @param statusCode Status code of the response 41 | * @param responseHeaders Headers of the response 42 | */ 43 | void onSuccess(T result, int statusCode, Map> responseHeaders); 44 | 45 | /** 46 | * This is called when the API upload processing. 47 | * 48 | * @param bytesWritten bytes Written 49 | * @param contentLength content length of request body 50 | * @param done write end 51 | */ 52 | void onUploadProgress(long bytesWritten, long contentLength, boolean done); 53 | 54 | /** 55 | * This is called when the API downlond processing. 56 | * 57 | * @param bytesRead bytes Read 58 | * @param contentLength content lenngth of the response 59 | * @param done Read end 60 | */ 61 | void onDownloadProgress(long bytesRead, long contentLength, boolean done); 62 | } 63 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/ApiException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | import java.util.Map; 17 | import java.util.List; 18 | 19 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 20 | public class ApiException extends Exception { 21 | private int code = 0; 22 | private Map> responseHeaders = null; 23 | private String responseBody = null; 24 | 25 | public ApiException() {} 26 | 27 | public ApiException(Throwable throwable) { 28 | super(throwable); 29 | } 30 | 31 | public ApiException(String message) { 32 | super(message); 33 | } 34 | 35 | public ApiException(String message, Throwable throwable, int code, Map> responseHeaders, String responseBody) { 36 | super(message, throwable); 37 | this.code = code; 38 | this.responseHeaders = responseHeaders; 39 | this.responseBody = responseBody; 40 | } 41 | 42 | public ApiException(String message, int code, Map> responseHeaders, String responseBody) { 43 | this(message, (Throwable) null, code, responseHeaders, responseBody); 44 | } 45 | 46 | public ApiException(String message, Throwable throwable, int code, Map> responseHeaders) { 47 | this(message, throwable, code, responseHeaders, null); 48 | } 49 | 50 | public ApiException(int code, Map> responseHeaders, String responseBody) { 51 | this((String) null, (Throwable) null, code, responseHeaders, responseBody); 52 | } 53 | 54 | public ApiException(int code, String message) { 55 | super(message); 56 | this.code = code; 57 | } 58 | 59 | public ApiException(int code, String message, Map> responseHeaders, String responseBody) { 60 | this(code, message); 61 | this.responseHeaders = responseHeaders; 62 | this.responseBody = responseBody; 63 | } 64 | 65 | /** 66 | * Get the HTTP status code. 67 | * 68 | * @return HTTP status code 69 | */ 70 | public int getCode() { 71 | return code; 72 | } 73 | 74 | /** 75 | * Get the HTTP response headers. 76 | * 77 | * @return A map of list of string 78 | */ 79 | public Map> getResponseHeaders() { 80 | return responseHeaders; 81 | } 82 | 83 | /** 84 | * Get the HTTP response body. 85 | * 86 | * @return Response body in the form of string 87 | */ 88 | public String getResponseBody() { 89 | return responseBody; 90 | } 91 | } 92 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/ApiResponse.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | import java.util.List; 17 | import java.util.Map; 18 | 19 | /** 20 | * API response returned by API call. 21 | * 22 | * @param The type of data that is deserialized from response body 23 | */ 24 | public class ApiResponse { 25 | final private int statusCode; 26 | final private Map> headers; 27 | final private T data; 28 | 29 | /** 30 | * @param statusCode The status code of HTTP response 31 | * @param headers The headers of HTTP response 32 | */ 33 | public ApiResponse(int statusCode, Map> headers) { 34 | this(statusCode, headers, null); 35 | } 36 | 37 | /** 38 | * @param statusCode The status code of HTTP response 39 | * @param headers The headers of HTTP response 40 | * @param data The object deserialized from response bod 41 | */ 42 | public ApiResponse(int statusCode, Map> headers, T data) { 43 | this.statusCode = statusCode; 44 | this.headers = headers; 45 | this.data = data; 46 | } 47 | 48 | public int getStatusCode() { 49 | return statusCode; 50 | } 51 | 52 | public Map> getHeaders() { 53 | return headers; 54 | } 55 | 56 | public T getData() { 57 | return data; 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/Configuration.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 17 | public class Configuration { 18 | private static ApiClient defaultApiClient = new ApiClient(); 19 | 20 | /** 21 | * Get the default API client, which would be used when creating API 22 | * instances without providing an API client. 23 | * 24 | * @return Default API client 25 | */ 26 | public static ApiClient getDefaultApiClient() { 27 | return defaultApiClient; 28 | } 29 | 30 | /** 31 | * Set the default API client, which would be used when creating API 32 | * instances without providing an API client. 33 | * 34 | * @param apiClient API client 35 | */ 36 | public static void setDefaultApiClient(ApiClient apiClient) { 37 | defaultApiClient = apiClient; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/GzipRequestInterceptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | import com.squareup.okhttp.*; 17 | import okio.Buffer; 18 | import okio.BufferedSink; 19 | import okio.GzipSink; 20 | import okio.Okio; 21 | 22 | import java.io.IOException; 23 | 24 | /** 25 | * Encodes request bodies using gzip. 26 | * 27 | * Taken from https://github.com/square/okhttp/issues/350 28 | */ 29 | class GzipRequestInterceptor implements Interceptor { 30 | @Override public Response intercept(Chain chain) throws IOException { 31 | Request originalRequest = chain.request(); 32 | if (originalRequest.body() == null || originalRequest.header("Content-Encoding") != null) { 33 | return chain.proceed(originalRequest); 34 | } 35 | 36 | Request compressedRequest = originalRequest.newBuilder() 37 | .header("Content-Encoding", "gzip") 38 | .method(originalRequest.method(), forceContentLength(gzip(originalRequest.body()))) 39 | .build(); 40 | return chain.proceed(compressedRequest); 41 | } 42 | 43 | private RequestBody forceContentLength(final RequestBody requestBody) throws IOException { 44 | final Buffer buffer = new Buffer(); 45 | requestBody.writeTo(buffer); 46 | return new RequestBody() { 47 | @Override 48 | public MediaType contentType() { 49 | return requestBody.contentType(); 50 | } 51 | 52 | @Override 53 | public long contentLength() { 54 | return buffer.size(); 55 | } 56 | 57 | @Override 58 | public void writeTo(BufferedSink sink) throws IOException { 59 | sink.write(buffer.snapshot()); 60 | } 61 | }; 62 | } 63 | 64 | private RequestBody gzip(final RequestBody body) { 65 | return new RequestBody() { 66 | @Override public MediaType contentType() { 67 | return body.contentType(); 68 | } 69 | 70 | @Override public long contentLength() { 71 | return -1; // We don't know the compressed length in advance! 72 | } 73 | 74 | @Override public void writeTo(BufferedSink sink) throws IOException { 75 | BufferedSink gzipSink = Okio.buffer(new GzipSink(sink)); 76 | body.writeTo(gzipSink); 77 | gzipSink.close(); 78 | } 79 | }; 80 | } 81 | } -------------------------------------------------------------------------------- /src/main/java/kubevirt/Pair.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 17 | public class Pair { 18 | private String name = ""; 19 | private String value = ""; 20 | 21 | public Pair (String name, String value) { 22 | setName(name); 23 | setValue(value); 24 | } 25 | 26 | private void setName(String name) { 27 | if (!isValidString(name)) return; 28 | 29 | this.name = name; 30 | } 31 | 32 | private void setValue(String value) { 33 | if (!isValidString(value)) return; 34 | 35 | this.value = value; 36 | } 37 | 38 | public String getName() { 39 | return this.name; 40 | } 41 | 42 | public String getValue() { 43 | return this.value; 44 | } 45 | 46 | private boolean isValidString(String arg) { 47 | if (arg == null) return false; 48 | if (arg.trim().isEmpty()) return false; 49 | 50 | return true; 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/ProgressRequestBody.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | import com.squareup.okhttp.MediaType; 17 | import com.squareup.okhttp.RequestBody; 18 | 19 | import java.io.IOException; 20 | 21 | import okio.Buffer; 22 | import okio.BufferedSink; 23 | import okio.ForwardingSink; 24 | import okio.Okio; 25 | import okio.Sink; 26 | 27 | public class ProgressRequestBody extends RequestBody { 28 | 29 | public interface ProgressRequestListener { 30 | void onRequestProgress(long bytesWritten, long contentLength, boolean done); 31 | } 32 | 33 | private final RequestBody requestBody; 34 | 35 | private final ProgressRequestListener progressListener; 36 | 37 | public ProgressRequestBody(RequestBody requestBody, ProgressRequestListener progressListener) { 38 | this.requestBody = requestBody; 39 | this.progressListener = progressListener; 40 | } 41 | 42 | @Override 43 | public MediaType contentType() { 44 | return requestBody.contentType(); 45 | } 46 | 47 | @Override 48 | public long contentLength() throws IOException { 49 | return requestBody.contentLength(); 50 | } 51 | 52 | @Override 53 | public void writeTo(BufferedSink sink) throws IOException { 54 | BufferedSink bufferedSink = Okio.buffer(sink(sink)); 55 | requestBody.writeTo(bufferedSink); 56 | bufferedSink.flush(); 57 | } 58 | 59 | private Sink sink(Sink sink) { 60 | return new ForwardingSink(sink) { 61 | 62 | long bytesWritten = 0L; 63 | long contentLength = 0L; 64 | 65 | @Override 66 | public void write(Buffer source, long byteCount) throws IOException { 67 | super.write(source, byteCount); 68 | if (contentLength == 0) { 69 | contentLength = contentLength(); 70 | } 71 | 72 | bytesWritten += byteCount; 73 | progressListener.onRequestProgress(bytesWritten, contentLength, bytesWritten == contentLength); 74 | } 75 | }; 76 | } 77 | } 78 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/ProgressResponseBody.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | import com.squareup.okhttp.MediaType; 17 | import com.squareup.okhttp.ResponseBody; 18 | 19 | import java.io.IOException; 20 | 21 | import okio.Buffer; 22 | import okio.BufferedSource; 23 | import okio.ForwardingSource; 24 | import okio.Okio; 25 | import okio.Source; 26 | 27 | public class ProgressResponseBody extends ResponseBody { 28 | 29 | public interface ProgressListener { 30 | void update(long bytesRead, long contentLength, boolean done); 31 | } 32 | 33 | private final ResponseBody responseBody; 34 | private final ProgressListener progressListener; 35 | private BufferedSource bufferedSource; 36 | 37 | public ProgressResponseBody(ResponseBody responseBody, ProgressListener progressListener) { 38 | this.responseBody = responseBody; 39 | this.progressListener = progressListener; 40 | } 41 | 42 | @Override 43 | public MediaType contentType() { 44 | return responseBody.contentType(); 45 | } 46 | 47 | @Override 48 | public long contentLength() throws IOException { 49 | return responseBody.contentLength(); 50 | } 51 | 52 | @Override 53 | public BufferedSource source() throws IOException { 54 | if (bufferedSource == null) { 55 | bufferedSource = Okio.buffer(source(responseBody.source())); 56 | } 57 | return bufferedSource; 58 | } 59 | 60 | private Source source(Source source) { 61 | return new ForwardingSource(source) { 62 | long totalBytesRead = 0L; 63 | 64 | @Override 65 | public long read(Buffer sink, long byteCount) throws IOException { 66 | long bytesRead = super.read(sink, byteCount); 67 | // read() returns the number of bytes read, or -1 if this source is exhausted. 68 | totalBytesRead += bytesRead != -1 ? bytesRead : 0; 69 | progressListener.update(totalBytesRead, responseBody.contentLength(), bytesRead == -1); 70 | return bytesRead; 71 | } 72 | }; 73 | } 74 | } 75 | 76 | 77 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/StringUtil.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt; 15 | 16 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 17 | public class StringUtil { 18 | /** 19 | * Check if the given array contains the given value (with case-insensitive comparison). 20 | * 21 | * @param array The array 22 | * @param value The value to search 23 | * @return true if the array contains the value 24 | */ 25 | public static boolean containsIgnoreCase(String[] array, String value) { 26 | for (String str : array) { 27 | if (value == null && str == null) return true; 28 | if (value != null && value.equalsIgnoreCase(str)) return true; 29 | } 30 | return false; 31 | } 32 | 33 | /** 34 | * Join an array of strings with the given separator. 35 | *

36 | * Note: This might be replaced by utility method from commons-lang or guava someday 37 | * if one of those libraries is added as dependency. 38 | *

39 | * 40 | * @param array The array of strings 41 | * @param separator The separator 42 | * @return the resulting string 43 | */ 44 | public static String join(String[] array, String separator) { 45 | int len = array.length; 46 | if (len == 0) return ""; 47 | 48 | StringBuilder out = new StringBuilder(); 49 | out.append(array[0]); 50 | for (int i = 1; i < len; i++) { 51 | out.append(separator).append(array[i]); 52 | } 53 | return out.toString(); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/auth/ApiKeyAuth.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.auth; 15 | 16 | import kubevirt.Pair; 17 | 18 | import java.util.Map; 19 | import java.util.List; 20 | 21 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 22 | public class ApiKeyAuth implements Authentication { 23 | private final String location; 24 | private final String paramName; 25 | 26 | private String apiKey; 27 | private String apiKeyPrefix; 28 | 29 | public ApiKeyAuth(String location, String paramName) { 30 | this.location = location; 31 | this.paramName = paramName; 32 | } 33 | 34 | public String getLocation() { 35 | return location; 36 | } 37 | 38 | public String getParamName() { 39 | return paramName; 40 | } 41 | 42 | public String getApiKey() { 43 | return apiKey; 44 | } 45 | 46 | public void setApiKey(String apiKey) { 47 | this.apiKey = apiKey; 48 | } 49 | 50 | public String getApiKeyPrefix() { 51 | return apiKeyPrefix; 52 | } 53 | 54 | public void setApiKeyPrefix(String apiKeyPrefix) { 55 | this.apiKeyPrefix = apiKeyPrefix; 56 | } 57 | 58 | @Override 59 | public void applyToParams(List queryParams, Map headerParams) { 60 | if (apiKey == null) { 61 | return; 62 | } 63 | String value; 64 | if (apiKeyPrefix != null) { 65 | value = apiKeyPrefix + " " + apiKey; 66 | } else { 67 | value = apiKey; 68 | } 69 | if ("query".equals(location)) { 70 | queryParams.add(new Pair(paramName, value)); 71 | } else if ("header".equals(location)) { 72 | headerParams.put(paramName, value); 73 | } 74 | } 75 | } 76 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/auth/Authentication.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.auth; 15 | 16 | import kubevirt.Pair; 17 | 18 | import java.util.Map; 19 | import java.util.List; 20 | 21 | public interface Authentication { 22 | /** 23 | * Apply authentication settings to header and query params. 24 | * 25 | * @param queryParams List of query parameters 26 | * @param headerParams Map of header parameters 27 | */ 28 | void applyToParams(List queryParams, Map headerParams); 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/auth/HttpBasicAuth.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.auth; 15 | 16 | import kubevirt.Pair; 17 | 18 | import com.squareup.okhttp.Credentials; 19 | 20 | import java.util.Map; 21 | import java.util.List; 22 | 23 | import java.io.UnsupportedEncodingException; 24 | 25 | public class HttpBasicAuth implements Authentication { 26 | private String username; 27 | private String password; 28 | 29 | public String getUsername() { 30 | return username; 31 | } 32 | 33 | public void setUsername(String username) { 34 | this.username = username; 35 | } 36 | 37 | public String getPassword() { 38 | return password; 39 | } 40 | 41 | public void setPassword(String password) { 42 | this.password = password; 43 | } 44 | 45 | @Override 46 | public void applyToParams(List queryParams, Map headerParams) { 47 | if (username == null && password == null) { 48 | return; 49 | } 50 | headerParams.put("Authorization", Credentials.basic( 51 | username == null ? "" : username, 52 | password == null ? "" : password)); 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/auth/OAuth.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.auth; 15 | 16 | import kubevirt.Pair; 17 | 18 | import java.util.Map; 19 | import java.util.List; 20 | 21 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 22 | public class OAuth implements Authentication { 23 | private String accessToken; 24 | 25 | public String getAccessToken() { 26 | return accessToken; 27 | } 28 | 29 | public void setAccessToken(String accessToken) { 30 | this.accessToken = accessToken; 31 | } 32 | 33 | @Override 34 | public void applyToParams(List queryParams, Map headerParams) { 35 | if (accessToken != null) { 36 | headerParams.put("Authorization", "Bearer " + accessToken); 37 | } 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/auth/OAuthFlow.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.auth; 15 | 16 | public enum OAuthFlow { 17 | accessCode, implicit, password, application 18 | } 19 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/TypesUID.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | 19 | /** 20 | * TypesUID 21 | */ 22 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 23 | public class TypesUID { 24 | 25 | @Override 26 | public boolean equals(java.lang.Object o) { 27 | if (this == o) { 28 | return true; 29 | } 30 | if (o == null || getClass() != o.getClass()) { 31 | return false; 32 | } 33 | return true; 34 | } 35 | 36 | @Override 37 | public int hashCode() { 38 | return Objects.hash(); 39 | } 40 | 41 | 42 | @Override 43 | public String toString() { 44 | StringBuilder sb = new StringBuilder(); 45 | sb.append("class TypesUID {\n"); 46 | 47 | sb.append("}"); 48 | return sb.toString(); 49 | } 50 | 51 | /** 52 | * Convert the given object to string with each line indented by 4 spaces 53 | * (except the first line). 54 | */ 55 | private String toIndentedString(java.lang.Object o) { 56 | if (o == null) { 57 | return "null"; 58 | } 59 | return o.toString().replace("\n", "\n "); 60 | } 61 | 62 | } 63 | 64 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1BIOS.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import io.swagger.annotations.ApiModel; 19 | 20 | /** 21 | * If set (default), BIOS will be used. 22 | */ 23 | @ApiModel(description = "If set (default), BIOS will be used.") 24 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 25 | public class V1BIOS { 26 | 27 | @Override 28 | public boolean equals(java.lang.Object o) { 29 | if (this == o) { 30 | return true; 31 | } 32 | if (o == null || getClass() != o.getClass()) { 33 | return false; 34 | } 35 | return true; 36 | } 37 | 38 | @Override 39 | public int hashCode() { 40 | return Objects.hash(); 41 | } 42 | 43 | 44 | @Override 45 | public String toString() { 46 | StringBuilder sb = new StringBuilder(); 47 | sb.append("class V1BIOS {\n"); 48 | 49 | sb.append("}"); 50 | return sb.toString(); 51 | } 52 | 53 | /** 54 | * Convert the given object to string with each line indented by 4 spaces 55 | * (except the first line). 56 | */ 57 | private String toIndentedString(java.lang.Object o) { 58 | if (o == null) { 59 | return "null"; 60 | } 61 | return o.toString().replace("\n", "\n "); 62 | } 63 | 64 | } 65 | 66 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Bootloader.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import kubevirt.io.V1BIOS; 27 | import kubevirt.io.V1EFI; 28 | 29 | /** 30 | * Represents the firmware blob used to assist in the domain creation process. Used for setting the QEMU BIOS file path for the libvirt domain. 31 | */ 32 | @ApiModel(description = "Represents the firmware blob used to assist in the domain creation process. Used for setting the QEMU BIOS file path for the libvirt domain.") 33 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 34 | public class V1Bootloader { 35 | @SerializedName("bios") 36 | private V1BIOS bios = null; 37 | 38 | @SerializedName("efi") 39 | private V1EFI efi = null; 40 | 41 | public V1Bootloader bios(V1BIOS bios) { 42 | this.bios = bios; 43 | return this; 44 | } 45 | 46 | /** 47 | * If set (default), BIOS will be used. +optional 48 | * @return bios 49 | **/ 50 | @ApiModelProperty(value = "If set (default), BIOS will be used. +optional") 51 | public V1BIOS getBios() { 52 | return bios; 53 | } 54 | 55 | public void setBios(V1BIOS bios) { 56 | this.bios = bios; 57 | } 58 | 59 | public V1Bootloader efi(V1EFI efi) { 60 | this.efi = efi; 61 | return this; 62 | } 63 | 64 | /** 65 | * If set, EFI will be used instead of BIOS. +optional 66 | * @return efi 67 | **/ 68 | @ApiModelProperty(value = "If set, EFI will be used instead of BIOS. +optional") 69 | public V1EFI getEfi() { 70 | return efi; 71 | } 72 | 73 | public void setEfi(V1EFI efi) { 74 | this.efi = efi; 75 | } 76 | 77 | 78 | @Override 79 | public boolean equals(java.lang.Object o) { 80 | if (this == o) { 81 | return true; 82 | } 83 | if (o == null || getClass() != o.getClass()) { 84 | return false; 85 | } 86 | V1Bootloader v1Bootloader = (V1Bootloader) o; 87 | return Objects.equals(this.bios, v1Bootloader.bios) && 88 | Objects.equals(this.efi, v1Bootloader.efi); 89 | } 90 | 91 | @Override 92 | public int hashCode() { 93 | return Objects.hash(bios, efi); 94 | } 95 | 96 | 97 | @Override 98 | public String toString() { 99 | StringBuilder sb = new StringBuilder(); 100 | sb.append("class V1Bootloader {\n"); 101 | 102 | sb.append(" bios: ").append(toIndentedString(bios)).append("\n"); 103 | sb.append(" efi: ").append(toIndentedString(efi)).append("\n"); 104 | sb.append("}"); 105 | return sb.toString(); 106 | } 107 | 108 | /** 109 | * Convert the given object to string with each line indented by 4 spaces 110 | * (except the first line). 111 | */ 112 | private String toIndentedString(java.lang.Object o) { 113 | if (o == null) { 114 | return "null"; 115 | } 116 | return o.toString().replace("\n", "\n "); 117 | } 118 | 119 | } 120 | 121 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1ClockOffsetUTC.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * UTC sets the guest clock to UTC on each boot. 29 | */ 30 | @ApiModel(description = "UTC sets the guest clock to UTC on each boot.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1ClockOffsetUTC { 33 | @SerializedName("offsetSeconds") 34 | private Integer offsetSeconds = null; 35 | 36 | public V1ClockOffsetUTC offsetSeconds(Integer offsetSeconds) { 37 | this.offsetSeconds = offsetSeconds; 38 | return this; 39 | } 40 | 41 | /** 42 | * OffsetSeconds specifies an offset in seconds, relative to UTC. If set, guest changes to the clock will be kept during reboots and not reset. 43 | * @return offsetSeconds 44 | **/ 45 | @ApiModelProperty(value = "OffsetSeconds specifies an offset in seconds, relative to UTC. If set, guest changes to the clock will be kept during reboots and not reset.") 46 | public Integer getOffsetSeconds() { 47 | return offsetSeconds; 48 | } 49 | 50 | public void setOffsetSeconds(Integer offsetSeconds) { 51 | this.offsetSeconds = offsetSeconds; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1ClockOffsetUTC v1ClockOffsetUTC = (V1ClockOffsetUTC) o; 64 | return Objects.equals(this.offsetSeconds, v1ClockOffsetUTC.offsetSeconds); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(offsetSeconds); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1ClockOffsetUTC {\n"); 77 | 78 | sb.append(" offsetSeconds: ").append(toIndentedString(offsetSeconds)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1ConfigMapVolumeSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * ConfigMapVolumeSource adapts a ConfigMap into a volume. More info: https://kubernetes.io/docs/concepts/storage/volumes/#configmap 29 | */ 30 | @ApiModel(description = "ConfigMapVolumeSource adapts a ConfigMap into a volume. More info: https://kubernetes.io/docs/concepts/storage/volumes/#configmap") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1ConfigMapVolumeSource { 33 | @SerializedName("name") 34 | private String name = null; 35 | 36 | @SerializedName("optional") 37 | private Boolean optional = null; 38 | 39 | public V1ConfigMapVolumeSource name(String name) { 40 | this.name = name; 41 | return this; 42 | } 43 | 44 | /** 45 | * Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names 46 | * @return name 47 | **/ 48 | @ApiModelProperty(value = "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names") 49 | public String getName() { 50 | return name; 51 | } 52 | 53 | public void setName(String name) { 54 | this.name = name; 55 | } 56 | 57 | public V1ConfigMapVolumeSource optional(Boolean optional) { 58 | this.optional = optional; 59 | return this; 60 | } 61 | 62 | /** 63 | * Specify whether the ConfigMap or it's keys must be defined +optional 64 | * @return optional 65 | **/ 66 | @ApiModelProperty(value = "Specify whether the ConfigMap or it's keys must be defined +optional") 67 | public Boolean isOptional() { 68 | return optional; 69 | } 70 | 71 | public void setOptional(Boolean optional) { 72 | this.optional = optional; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1ConfigMapVolumeSource v1ConfigMapVolumeSource = (V1ConfigMapVolumeSource) o; 85 | return Objects.equals(this.name, v1ConfigMapVolumeSource.name) && 86 | Objects.equals(this.optional, v1ConfigMapVolumeSource.optional); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(name, optional); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1ConfigMapVolumeSource {\n"); 99 | 100 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 101 | sb.append(" optional: ").append(toIndentedString(optional)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1DHCPPrivateOptions.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * DHCPExtraOptions defines Extra DHCP options for a VM. 29 | */ 30 | @ApiModel(description = "DHCPExtraOptions defines Extra DHCP options for a VM.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1DHCPPrivateOptions { 33 | @SerializedName("option") 34 | private Integer option = null; 35 | 36 | @SerializedName("value") 37 | private String value = null; 38 | 39 | public V1DHCPPrivateOptions option(Integer option) { 40 | this.option = option; 41 | return this; 42 | } 43 | 44 | /** 45 | * Option is an Integer value from 224-254 Required. 46 | * @return option 47 | **/ 48 | @ApiModelProperty(required = true, value = "Option is an Integer value from 224-254 Required.") 49 | public Integer getOption() { 50 | return option; 51 | } 52 | 53 | public void setOption(Integer option) { 54 | this.option = option; 55 | } 56 | 57 | public V1DHCPPrivateOptions value(String value) { 58 | this.value = value; 59 | return this; 60 | } 61 | 62 | /** 63 | * Value is a String value for the Option provided Required. 64 | * @return value 65 | **/ 66 | @ApiModelProperty(required = true, value = "Value is a String value for the Option provided Required.") 67 | public String getValue() { 68 | return value; 69 | } 70 | 71 | public void setValue(String value) { 72 | this.value = value; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1DHCPPrivateOptions v1DHCPPrivateOptions = (V1DHCPPrivateOptions) o; 85 | return Objects.equals(this.option, v1DHCPPrivateOptions.option) && 86 | Objects.equals(this.value, v1DHCPPrivateOptions.value); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(option, value); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1DHCPPrivateOptions {\n"); 99 | 100 | sb.append(" option: ").append(toIndentedString(option)).append("\n"); 101 | sb.append(" value: ").append(toIndentedString(value)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1DataVolumeSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1DataVolumeSource 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1DataVolumeSource { 32 | @SerializedName("name") 33 | private String name = null; 34 | 35 | public V1DataVolumeSource name(String name) { 36 | this.name = name; 37 | return this; 38 | } 39 | 40 | /** 41 | * Name represents the name of the DataVolume in the same namespace 42 | * @return name 43 | **/ 44 | @ApiModelProperty(required = true, value = "Name represents the name of the DataVolume in the same namespace") 45 | public String getName() { 46 | return name; 47 | } 48 | 49 | public void setName(String name) { 50 | this.name = name; 51 | } 52 | 53 | 54 | @Override 55 | public boolean equals(java.lang.Object o) { 56 | if (this == o) { 57 | return true; 58 | } 59 | if (o == null || getClass() != o.getClass()) { 60 | return false; 61 | } 62 | V1DataVolumeSource v1DataVolumeSource = (V1DataVolumeSource) o; 63 | return Objects.equals(this.name, v1DataVolumeSource.name); 64 | } 65 | 66 | @Override 67 | public int hashCode() { 68 | return Objects.hash(name); 69 | } 70 | 71 | 72 | @Override 73 | public String toString() { 74 | StringBuilder sb = new StringBuilder(); 75 | sb.append("class V1DataVolumeSource {\n"); 76 | 77 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 78 | sb.append("}"); 79 | return sb.toString(); 80 | } 81 | 82 | /** 83 | * Convert the given object to string with each line indented by 4 spaces 84 | * (except the first line). 85 | */ 86 | private String toIndentedString(java.lang.Object o) { 87 | if (o == null) { 88 | return "null"; 89 | } 90 | return o.toString().replace("\n", "\n "); 91 | } 92 | 93 | } 94 | 95 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1EFI.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import io.swagger.annotations.ApiModel; 19 | 20 | /** 21 | * If set, EFI will be used instead of BIOS. 22 | */ 23 | @ApiModel(description = "If set, EFI will be used instead of BIOS.") 24 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 25 | public class V1EFI { 26 | 27 | @Override 28 | public boolean equals(java.lang.Object o) { 29 | if (this == o) { 30 | return true; 31 | } 32 | if (o == null || getClass() != o.getClass()) { 33 | return false; 34 | } 35 | return true; 36 | } 37 | 38 | @Override 39 | public int hashCode() { 40 | return Objects.hash(); 41 | } 42 | 43 | 44 | @Override 45 | public String toString() { 46 | StringBuilder sb = new StringBuilder(); 47 | sb.append("class V1EFI {\n"); 48 | 49 | sb.append("}"); 50 | return sb.toString(); 51 | } 52 | 53 | /** 54 | * Convert the given object to string with each line indented by 4 spaces 55 | * (except the first line). 56 | */ 57 | private String toIndentedString(java.lang.Object o) { 58 | if (o == null) { 59 | return "null"; 60 | } 61 | return o.toString().replace("\n", "\n "); 62 | } 63 | 64 | } 65 | 66 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1EmptyDiskSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * EmptyDisk represents a temporary disk which shares the vmis lifecycle. 29 | */ 30 | @ApiModel(description = "EmptyDisk represents a temporary disk which shares the vmis lifecycle.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1EmptyDiskSource { 33 | @SerializedName("capacity") 34 | private String capacity = null; 35 | 36 | public V1EmptyDiskSource capacity(String capacity) { 37 | this.capacity = capacity; 38 | return this; 39 | } 40 | 41 | /** 42 | * Capacity of the sparse disk. 43 | * @return capacity 44 | **/ 45 | @ApiModelProperty(required = true, value = "Capacity of the sparse disk.") 46 | public String getCapacity() { 47 | return capacity; 48 | } 49 | 50 | public void setCapacity(String capacity) { 51 | this.capacity = capacity; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1EmptyDiskSource v1EmptyDiskSource = (V1EmptyDiskSource) o; 64 | return Objects.equals(this.capacity, v1EmptyDiskSource.capacity); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(capacity); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1EmptyDiskSource {\n"); 77 | 78 | sb.append(" capacity: ").append(toIndentedString(capacity)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1EphemeralVolumeSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import kubevirt.io.V1PersistentVolumeClaimVolumeSource; 27 | 28 | /** 29 | * V1EphemeralVolumeSource 30 | */ 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1EphemeralVolumeSource { 33 | @SerializedName("persistentVolumeClaim") 34 | private V1PersistentVolumeClaimVolumeSource persistentVolumeClaim = null; 35 | 36 | public V1EphemeralVolumeSource persistentVolumeClaim(V1PersistentVolumeClaimVolumeSource persistentVolumeClaim) { 37 | this.persistentVolumeClaim = persistentVolumeClaim; 38 | return this; 39 | } 40 | 41 | /** 42 | * PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. Directly attached to the vmi via qemu. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims +optional 43 | * @return persistentVolumeClaim 44 | **/ 45 | @ApiModelProperty(value = "PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. Directly attached to the vmi via qemu. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims +optional") 46 | public V1PersistentVolumeClaimVolumeSource getPersistentVolumeClaim() { 47 | return persistentVolumeClaim; 48 | } 49 | 50 | public void setPersistentVolumeClaim(V1PersistentVolumeClaimVolumeSource persistentVolumeClaim) { 51 | this.persistentVolumeClaim = persistentVolumeClaim; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1EphemeralVolumeSource v1EphemeralVolumeSource = (V1EphemeralVolumeSource) o; 64 | return Objects.equals(this.persistentVolumeClaim, v1EphemeralVolumeSource.persistentVolumeClaim); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(persistentVolumeClaim); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1EphemeralVolumeSource {\n"); 77 | 78 | sb.append(" persistentVolumeClaim: ").append(toIndentedString(persistentVolumeClaim)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1FeatureAPIC.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1FeatureAPIC 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1FeatureAPIC { 32 | @SerializedName("enabled") 33 | private Boolean enabled = null; 34 | 35 | @SerializedName("endOfInterrupt") 36 | private Boolean endOfInterrupt = null; 37 | 38 | public V1FeatureAPIC enabled(Boolean enabled) { 39 | this.enabled = enabled; 40 | return this; 41 | } 42 | 43 | /** 44 | * Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional 45 | * @return enabled 46 | **/ 47 | @ApiModelProperty(value = "Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional") 48 | public Boolean isEnabled() { 49 | return enabled; 50 | } 51 | 52 | public void setEnabled(Boolean enabled) { 53 | this.enabled = enabled; 54 | } 55 | 56 | public V1FeatureAPIC endOfInterrupt(Boolean endOfInterrupt) { 57 | this.endOfInterrupt = endOfInterrupt; 58 | return this; 59 | } 60 | 61 | /** 62 | * EndOfInterrupt enables the end of interrupt notification in the guest. Defaults to false. +optional 63 | * @return endOfInterrupt 64 | **/ 65 | @ApiModelProperty(value = "EndOfInterrupt enables the end of interrupt notification in the guest. Defaults to false. +optional") 66 | public Boolean isEndOfInterrupt() { 67 | return endOfInterrupt; 68 | } 69 | 70 | public void setEndOfInterrupt(Boolean endOfInterrupt) { 71 | this.endOfInterrupt = endOfInterrupt; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1FeatureAPIC v1FeatureAPIC = (V1FeatureAPIC) o; 84 | return Objects.equals(this.enabled, v1FeatureAPIC.enabled) && 85 | Objects.equals(this.endOfInterrupt, v1FeatureAPIC.endOfInterrupt); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(enabled, endOfInterrupt); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1FeatureAPIC {\n"); 98 | 99 | sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); 100 | sb.append(" endOfInterrupt: ").append(toIndentedString(endOfInterrupt)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1FeatureSpinlocks.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1FeatureSpinlocks 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1FeatureSpinlocks { 32 | @SerializedName("enabled") 33 | private Boolean enabled = null; 34 | 35 | @SerializedName("spinlocks") 36 | private Integer spinlocks = null; 37 | 38 | public V1FeatureSpinlocks enabled(Boolean enabled) { 39 | this.enabled = enabled; 40 | return this; 41 | } 42 | 43 | /** 44 | * Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional 45 | * @return enabled 46 | **/ 47 | @ApiModelProperty(value = "Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional") 48 | public Boolean isEnabled() { 49 | return enabled; 50 | } 51 | 52 | public void setEnabled(Boolean enabled) { 53 | this.enabled = enabled; 54 | } 55 | 56 | public V1FeatureSpinlocks spinlocks(Integer spinlocks) { 57 | this.spinlocks = spinlocks; 58 | return this; 59 | } 60 | 61 | /** 62 | * Retries indicates the number of retries. Must be a value greater or equal 4096. Defaults to 4096. +optional 63 | * @return spinlocks 64 | **/ 65 | @ApiModelProperty(value = "Retries indicates the number of retries. Must be a value greater or equal 4096. Defaults to 4096. +optional") 66 | public Integer getSpinlocks() { 67 | return spinlocks; 68 | } 69 | 70 | public void setSpinlocks(Integer spinlocks) { 71 | this.spinlocks = spinlocks; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1FeatureSpinlocks v1FeatureSpinlocks = (V1FeatureSpinlocks) o; 84 | return Objects.equals(this.enabled, v1FeatureSpinlocks.enabled) && 85 | Objects.equals(this.spinlocks, v1FeatureSpinlocks.spinlocks); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(enabled, spinlocks); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1FeatureSpinlocks {\n"); 98 | 99 | sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); 100 | sb.append(" spinlocks: ").append(toIndentedString(spinlocks)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1FeatureState.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * Represents if a feature is enabled or disabled. 29 | */ 30 | @ApiModel(description = "Represents if a feature is enabled or disabled.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1FeatureState { 33 | @SerializedName("enabled") 34 | private Boolean enabled = null; 35 | 36 | public V1FeatureState enabled(Boolean enabled) { 37 | this.enabled = enabled; 38 | return this; 39 | } 40 | 41 | /** 42 | * Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional 43 | * @return enabled 44 | **/ 45 | @ApiModelProperty(value = "Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional") 46 | public Boolean isEnabled() { 47 | return enabled; 48 | } 49 | 50 | public void setEnabled(Boolean enabled) { 51 | this.enabled = enabled; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1FeatureState v1FeatureState = (V1FeatureState) o; 64 | return Objects.equals(this.enabled, v1FeatureState.enabled); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(enabled); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1FeatureState {\n"); 77 | 78 | sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1FeatureVendorID.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1FeatureVendorID 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1FeatureVendorID { 32 | @SerializedName("enabled") 33 | private Boolean enabled = null; 34 | 35 | @SerializedName("vendorid") 36 | private String vendorid = null; 37 | 38 | public V1FeatureVendorID enabled(Boolean enabled) { 39 | this.enabled = enabled; 40 | return this; 41 | } 42 | 43 | /** 44 | * Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional 45 | * @return enabled 46 | **/ 47 | @ApiModelProperty(value = "Enabled determines if the feature should be enabled or disabled on the guest. Defaults to true. +optional") 48 | public Boolean isEnabled() { 49 | return enabled; 50 | } 51 | 52 | public void setEnabled(Boolean enabled) { 53 | this.enabled = enabled; 54 | } 55 | 56 | public V1FeatureVendorID vendorid(String vendorid) { 57 | this.vendorid = vendorid; 58 | return this; 59 | } 60 | 61 | /** 62 | * VendorID sets the hypervisor vendor id, visible to the vmi. String up to twelve characters. 63 | * @return vendorid 64 | **/ 65 | @ApiModelProperty(value = "VendorID sets the hypervisor vendor id, visible to the vmi. String up to twelve characters.") 66 | public String getVendorid() { 67 | return vendorid; 68 | } 69 | 70 | public void setVendorid(String vendorid) { 71 | this.vendorid = vendorid; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1FeatureVendorID v1FeatureVendorID = (V1FeatureVendorID) o; 84 | return Objects.equals(this.enabled, v1FeatureVendorID.enabled) && 85 | Objects.equals(this.vendorid, v1FeatureVendorID.vendorid); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(enabled, vendorid); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1FeatureVendorID {\n"); 98 | 99 | sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); 100 | sb.append(" vendorid: ").append(toIndentedString(vendorid)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1FloppyTarget.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1FloppyTarget 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1FloppyTarget { 32 | @SerializedName("readonly") 33 | private Boolean readonly = null; 34 | 35 | @SerializedName("tray") 36 | private String tray = null; 37 | 38 | public V1FloppyTarget readonly(Boolean readonly) { 39 | this.readonly = readonly; 40 | return this; 41 | } 42 | 43 | /** 44 | * ReadOnly. Defaults to false. 45 | * @return readonly 46 | **/ 47 | @ApiModelProperty(value = "ReadOnly. Defaults to false.") 48 | public Boolean isReadonly() { 49 | return readonly; 50 | } 51 | 52 | public void setReadonly(Boolean readonly) { 53 | this.readonly = readonly; 54 | } 55 | 56 | public V1FloppyTarget tray(String tray) { 57 | this.tray = tray; 58 | return this; 59 | } 60 | 61 | /** 62 | * Tray indicates if the tray of the device is open or closed. Allowed values are \"open\" and \"closed\". Defaults to closed. +optional 63 | * @return tray 64 | **/ 65 | @ApiModelProperty(value = "Tray indicates if the tray of the device is open or closed. Allowed values are \"open\" and \"closed\". Defaults to closed. +optional") 66 | public String getTray() { 67 | return tray; 68 | } 69 | 70 | public void setTray(String tray) { 71 | this.tray = tray; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1FloppyTarget v1FloppyTarget = (V1FloppyTarget) o; 84 | return Objects.equals(this.readonly, v1FloppyTarget.readonly) && 85 | Objects.equals(this.tray, v1FloppyTarget.tray); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(readonly, tray); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1FloppyTarget {\n"); 98 | 99 | sb.append(" readonly: ").append(toIndentedString(readonly)).append("\n"); 100 | sb.append(" tray: ").append(toIndentedString(tray)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1GPU.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1GPU 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1GPU { 32 | @SerializedName("deviceName") 33 | private String deviceName = null; 34 | 35 | @SerializedName("name") 36 | private String name = null; 37 | 38 | public V1GPU deviceName(String deviceName) { 39 | this.deviceName = deviceName; 40 | return this; 41 | } 42 | 43 | /** 44 | * Get deviceName 45 | * @return deviceName 46 | **/ 47 | @ApiModelProperty(required = true, value = "") 48 | public String getDeviceName() { 49 | return deviceName; 50 | } 51 | 52 | public void setDeviceName(String deviceName) { 53 | this.deviceName = deviceName; 54 | } 55 | 56 | public V1GPU name(String name) { 57 | this.name = name; 58 | return this; 59 | } 60 | 61 | /** 62 | * Name of the GPU device as exposed by a device plugin 63 | * @return name 64 | **/ 65 | @ApiModelProperty(required = true, value = "Name of the GPU device as exposed by a device plugin") 66 | public String getName() { 67 | return name; 68 | } 69 | 70 | public void setName(String name) { 71 | this.name = name; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1GPU v1GPU = (V1GPU) o; 84 | return Objects.equals(this.deviceName, v1GPU.deviceName) && 85 | Objects.equals(this.name, v1GPU.name); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(deviceName, name); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1GPU {\n"); 98 | 99 | sb.append(" deviceName: ").append(toIndentedString(deviceName)).append("\n"); 100 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1GenieNetwork.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * Represents the genie cni network. 29 | */ 30 | @ApiModel(description = "Represents the genie cni network.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1GenieNetwork { 33 | @SerializedName("networkName") 34 | private String networkName = null; 35 | 36 | public V1GenieNetwork networkName(String networkName) { 37 | this.networkName = networkName; 38 | return this; 39 | } 40 | 41 | /** 42 | * References the CNI plugin name. 43 | * @return networkName 44 | **/ 45 | @ApiModelProperty(required = true, value = "References the CNI plugin name.") 46 | public String getNetworkName() { 47 | return networkName; 48 | } 49 | 50 | public void setNetworkName(String networkName) { 51 | this.networkName = networkName; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1GenieNetwork v1GenieNetwork = (V1GenieNetwork) o; 64 | return Objects.equals(this.networkName, v1GenieNetwork.networkName); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(networkName); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1GenieNetwork {\n"); 77 | 78 | sb.append(" networkName: ").append(toIndentedString(networkName)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1HPETTimer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1HPETTimer 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1HPETTimer { 32 | @SerializedName("present") 33 | private Boolean present = null; 34 | 35 | @SerializedName("tickPolicy") 36 | private String tickPolicy = null; 37 | 38 | public V1HPETTimer present(Boolean present) { 39 | this.present = present; 40 | return this; 41 | } 42 | 43 | /** 44 | * Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional 45 | * @return present 46 | **/ 47 | @ApiModelProperty(value = "Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional") 48 | public Boolean isPresent() { 49 | return present; 50 | } 51 | 52 | public void setPresent(Boolean present) { 53 | this.present = present; 54 | } 55 | 56 | public V1HPETTimer tickPolicy(String tickPolicy) { 57 | this.tickPolicy = tickPolicy; 58 | return this; 59 | } 60 | 61 | /** 62 | * TickPolicy determines what happens when QEMU misses a deadline for injecting a tick to the guest. One of \"delay\", \"catchup\", \"merge\", \"discard\". 63 | * @return tickPolicy 64 | **/ 65 | @ApiModelProperty(value = "TickPolicy determines what happens when QEMU misses a deadline for injecting a tick to the guest. One of \"delay\", \"catchup\", \"merge\", \"discard\".") 66 | public String getTickPolicy() { 67 | return tickPolicy; 68 | } 69 | 70 | public void setTickPolicy(String tickPolicy) { 71 | this.tickPolicy = tickPolicy; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1HPETTimer v1HPETTimer = (V1HPETTimer) o; 84 | return Objects.equals(this.present, v1HPETTimer.present) && 85 | Objects.equals(this.tickPolicy, v1HPETTimer.tickPolicy); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(present, tickPolicy); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1HPETTimer {\n"); 98 | 99 | sb.append(" present: ").append(toIndentedString(present)).append("\n"); 100 | sb.append(" tickPolicy: ").append(toIndentedString(tickPolicy)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1HTTPHeader.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * HTTPHeader describes a custom header to be used in HTTP probes 29 | */ 30 | @ApiModel(description = "HTTPHeader describes a custom header to be used in HTTP probes") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1HTTPHeader { 33 | @SerializedName("name") 34 | private String name = null; 35 | 36 | @SerializedName("value") 37 | private String value = null; 38 | 39 | public V1HTTPHeader name(String name) { 40 | this.name = name; 41 | return this; 42 | } 43 | 44 | /** 45 | * The header field name 46 | * @return name 47 | **/ 48 | @ApiModelProperty(required = true, value = "The header field name") 49 | public String getName() { 50 | return name; 51 | } 52 | 53 | public void setName(String name) { 54 | this.name = name; 55 | } 56 | 57 | public V1HTTPHeader value(String value) { 58 | this.value = value; 59 | return this; 60 | } 61 | 62 | /** 63 | * The header field value 64 | * @return value 65 | **/ 66 | @ApiModelProperty(required = true, value = "The header field value") 67 | public String getValue() { 68 | return value; 69 | } 70 | 71 | public void setValue(String value) { 72 | this.value = value; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1HTTPHeader v1HTTPHeader = (V1HTTPHeader) o; 85 | return Objects.equals(this.name, v1HTTPHeader.name) && 86 | Objects.equals(this.value, v1HTTPHeader.value); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(name, value); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1HTTPHeader {\n"); 99 | 100 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 101 | sb.append(" value: ").append(toIndentedString(value)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Hugepages.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * Hugepages allow to use hugepages for the VirtualMachineInstance instead of regular memory. 29 | */ 30 | @ApiModel(description = "Hugepages allow to use hugepages for the VirtualMachineInstance instead of regular memory.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1Hugepages { 33 | @SerializedName("pageSize") 34 | private String pageSize = null; 35 | 36 | public V1Hugepages pageSize(String pageSize) { 37 | this.pageSize = pageSize; 38 | return this; 39 | } 40 | 41 | /** 42 | * PageSize specifies the hugepage size, for x86_64 architecture valid values are 1Gi and 2Mi. 43 | * @return pageSize 44 | **/ 45 | @ApiModelProperty(value = "PageSize specifies the hugepage size, for x86_64 architecture valid values are 1Gi and 2Mi.") 46 | public String getPageSize() { 47 | return pageSize; 48 | } 49 | 50 | public void setPageSize(String pageSize) { 51 | this.pageSize = pageSize; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1Hugepages v1Hugepages = (V1Hugepages) o; 64 | return Objects.equals(this.pageSize, v1Hugepages.pageSize); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(pageSize); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1Hugepages {\n"); 77 | 78 | sb.append(" pageSize: ").append(toIndentedString(pageSize)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1HypervTimer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1HypervTimer 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1HypervTimer { 32 | @SerializedName("present") 33 | private Boolean present = null; 34 | 35 | public V1HypervTimer present(Boolean present) { 36 | this.present = present; 37 | return this; 38 | } 39 | 40 | /** 41 | * Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional 42 | * @return present 43 | **/ 44 | @ApiModelProperty(value = "Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional") 45 | public Boolean isPresent() { 46 | return present; 47 | } 48 | 49 | public void setPresent(Boolean present) { 50 | this.present = present; 51 | } 52 | 53 | 54 | @Override 55 | public boolean equals(java.lang.Object o) { 56 | if (this == o) { 57 | return true; 58 | } 59 | if (o == null || getClass() != o.getClass()) { 60 | return false; 61 | } 62 | V1HypervTimer v1HypervTimer = (V1HypervTimer) o; 63 | return Objects.equals(this.present, v1HypervTimer.present); 64 | } 65 | 66 | @Override 67 | public int hashCode() { 68 | return Objects.hash(present); 69 | } 70 | 71 | 72 | @Override 73 | public String toString() { 74 | StringBuilder sb = new StringBuilder(); 75 | sb.append("class V1HypervTimer {\n"); 76 | 77 | sb.append(" present: ").append(toIndentedString(present)).append("\n"); 78 | sb.append("}"); 79 | return sb.toString(); 80 | } 81 | 82 | /** 83 | * Convert the given object to string with each line indented by 4 spaces 84 | * (except the first line). 85 | */ 86 | private String toIndentedString(java.lang.Object o) { 87 | if (o == null) { 88 | return "null"; 89 | } 90 | return o.toString().replace("\n", "\n "); 91 | } 92 | 93 | } 94 | 95 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1I6300ESBWatchdog.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * i6300esb watchdog device. 29 | */ 30 | @ApiModel(description = "i6300esb watchdog device.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1I6300ESBWatchdog { 33 | @SerializedName("action") 34 | private String action = null; 35 | 36 | public V1I6300ESBWatchdog action(String action) { 37 | this.action = action; 38 | return this; 39 | } 40 | 41 | /** 42 | * The action to take. Valid values are poweroff, reset, shutdown. Defaults to reset. 43 | * @return action 44 | **/ 45 | @ApiModelProperty(value = "The action to take. Valid values are poweroff, reset, shutdown. Defaults to reset.") 46 | public String getAction() { 47 | return action; 48 | } 49 | 50 | public void setAction(String action) { 51 | this.action = action; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1I6300ESBWatchdog v1I6300ESBWatchdog = (V1I6300ESBWatchdog) o; 64 | return Objects.equals(this.action, v1I6300ESBWatchdog.action); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(action); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1I6300ESBWatchdog {\n"); 77 | 78 | sb.append(" action: ").append(toIndentedString(action)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Initializer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * Initializer is information about an initializer that has not yet completed. 29 | */ 30 | @ApiModel(description = "Initializer is information about an initializer that has not yet completed.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1Initializer { 33 | @SerializedName("name") 34 | private String name = null; 35 | 36 | public V1Initializer name(String name) { 37 | this.name = name; 38 | return this; 39 | } 40 | 41 | /** 42 | * name of the process that is responsible for initializing this object. 43 | * @return name 44 | **/ 45 | @ApiModelProperty(required = true, value = "name of the process that is responsible for initializing this object.") 46 | public String getName() { 47 | return name; 48 | } 49 | 50 | public void setName(String name) { 51 | this.name = name; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1Initializer v1Initializer = (V1Initializer) o; 64 | return Objects.equals(this.name, v1Initializer.name); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(name); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1Initializer {\n"); 77 | 78 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1InterfaceBridge.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | 19 | /** 20 | * V1InterfaceBridge 21 | */ 22 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 23 | public class V1InterfaceBridge { 24 | 25 | @Override 26 | public boolean equals(java.lang.Object o) { 27 | if (this == o) { 28 | return true; 29 | } 30 | if (o == null || getClass() != o.getClass()) { 31 | return false; 32 | } 33 | return true; 34 | } 35 | 36 | @Override 37 | public int hashCode() { 38 | return Objects.hash(); 39 | } 40 | 41 | 42 | @Override 43 | public String toString() { 44 | StringBuilder sb = new StringBuilder(); 45 | sb.append("class V1InterfaceBridge {\n"); 46 | 47 | sb.append("}"); 48 | return sb.toString(); 49 | } 50 | 51 | /** 52 | * Convert the given object to string with each line indented by 4 spaces 53 | * (except the first line). 54 | */ 55 | private String toIndentedString(java.lang.Object o) { 56 | if (o == null) { 57 | return "null"; 58 | } 59 | return o.toString().replace("\n", "\n "); 60 | } 61 | 62 | } 63 | 64 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1InterfaceMasquerade.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | 19 | /** 20 | * V1InterfaceMasquerade 21 | */ 22 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 23 | public class V1InterfaceMasquerade { 24 | 25 | @Override 26 | public boolean equals(java.lang.Object o) { 27 | if (this == o) { 28 | return true; 29 | } 30 | if (o == null || getClass() != o.getClass()) { 31 | return false; 32 | } 33 | return true; 34 | } 35 | 36 | @Override 37 | public int hashCode() { 38 | return Objects.hash(); 39 | } 40 | 41 | 42 | @Override 43 | public String toString() { 44 | StringBuilder sb = new StringBuilder(); 45 | sb.append("class V1InterfaceMasquerade {\n"); 46 | 47 | sb.append("}"); 48 | return sb.toString(); 49 | } 50 | 51 | /** 52 | * Convert the given object to string with each line indented by 4 spaces 53 | * (except the first line). 54 | */ 55 | private String toIndentedString(java.lang.Object o) { 56 | if (o == null) { 57 | return "null"; 58 | } 59 | return o.toString().replace("\n", "\n "); 60 | } 61 | 62 | } 63 | 64 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1InterfaceSRIOV.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | 19 | /** 20 | * V1InterfaceSRIOV 21 | */ 22 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 23 | public class V1InterfaceSRIOV { 24 | 25 | @Override 26 | public boolean equals(java.lang.Object o) { 27 | if (this == o) { 28 | return true; 29 | } 30 | if (o == null || getClass() != o.getClass()) { 31 | return false; 32 | } 33 | return true; 34 | } 35 | 36 | @Override 37 | public int hashCode() { 38 | return Objects.hash(); 39 | } 40 | 41 | 42 | @Override 43 | public String toString() { 44 | StringBuilder sb = new StringBuilder(); 45 | sb.append("class V1InterfaceSRIOV {\n"); 46 | 47 | sb.append("}"); 48 | return sb.toString(); 49 | } 50 | 51 | /** 52 | * Convert the given object to string with each line indented by 4 spaces 53 | * (except the first line). 54 | */ 55 | private String toIndentedString(java.lang.Object o) { 56 | if (o == null) { 57 | return "null"; 58 | } 59 | return o.toString().replace("\n", "\n "); 60 | } 61 | 62 | } 63 | 64 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1InterfaceSlirp.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | 19 | /** 20 | * V1InterfaceSlirp 21 | */ 22 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 23 | public class V1InterfaceSlirp { 24 | 25 | @Override 26 | public boolean equals(java.lang.Object o) { 27 | if (this == o) { 28 | return true; 29 | } 30 | if (o == null || getClass() != o.getClass()) { 31 | return false; 32 | } 33 | return true; 34 | } 35 | 36 | @Override 37 | public int hashCode() { 38 | return Objects.hash(); 39 | } 40 | 41 | 42 | @Override 43 | public String toString() { 44 | StringBuilder sb = new StringBuilder(); 45 | sb.append("class V1InterfaceSlirp {\n"); 46 | 47 | sb.append("}"); 48 | return sb.toString(); 49 | } 50 | 51 | /** 52 | * Convert the given object to string with each line indented by 4 spaces 53 | * (except the first line). 54 | */ 55 | private String toIndentedString(java.lang.Object o) { 56 | if (o == null) { 57 | return "null"; 58 | } 59 | return o.toString().replace("\n", "\n "); 60 | } 61 | 62 | } 63 | 64 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1KVMTimer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1KVMTimer 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1KVMTimer { 32 | @SerializedName("present") 33 | private Boolean present = null; 34 | 35 | public V1KVMTimer present(Boolean present) { 36 | this.present = present; 37 | return this; 38 | } 39 | 40 | /** 41 | * Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional 42 | * @return present 43 | **/ 44 | @ApiModelProperty(value = "Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional") 45 | public Boolean isPresent() { 46 | return present; 47 | } 48 | 49 | public void setPresent(Boolean present) { 50 | this.present = present; 51 | } 52 | 53 | 54 | @Override 55 | public boolean equals(java.lang.Object o) { 56 | if (this == o) { 57 | return true; 58 | } 59 | if (o == null || getClass() != o.getClass()) { 60 | return false; 61 | } 62 | V1KVMTimer v1KVMTimer = (V1KVMTimer) o; 63 | return Objects.equals(this.present, v1KVMTimer.present); 64 | } 65 | 66 | @Override 67 | public int hashCode() { 68 | return Objects.hash(present); 69 | } 70 | 71 | 72 | @Override 73 | public String toString() { 74 | StringBuilder sb = new StringBuilder(); 75 | sb.append("class V1KVMTimer {\n"); 76 | 77 | sb.append(" present: ").append(toIndentedString(present)).append("\n"); 78 | sb.append("}"); 79 | return sb.toString(); 80 | } 81 | 82 | /** 83 | * Convert the given object to string with each line indented by 4 spaces 84 | * (except the first line). 85 | */ 86 | private String toIndentedString(java.lang.Object o) { 87 | if (o == null) { 88 | return "null"; 89 | } 90 | return o.toString().replace("\n", "\n "); 91 | } 92 | 93 | } 94 | 95 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1LocalObjectReference.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace. 29 | */ 30 | @ApiModel(description = "LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1LocalObjectReference { 33 | @SerializedName("name") 34 | private String name = null; 35 | 36 | public V1LocalObjectReference name(String name) { 37 | this.name = name; 38 | return this; 39 | } 40 | 41 | /** 42 | * Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names 43 | * @return name 44 | **/ 45 | @ApiModelProperty(value = "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names") 46 | public String getName() { 47 | return name; 48 | } 49 | 50 | public void setName(String name) { 51 | this.name = name; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1LocalObjectReference v1LocalObjectReference = (V1LocalObjectReference) o; 64 | return Objects.equals(this.name, v1LocalObjectReference.name); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(name); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1LocalObjectReference {\n"); 77 | 78 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1LunTarget.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1LunTarget 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1LunTarget { 32 | @SerializedName("bus") 33 | private String bus = null; 34 | 35 | @SerializedName("readonly") 36 | private Boolean readonly = null; 37 | 38 | public V1LunTarget bus(String bus) { 39 | this.bus = bus; 40 | return this; 41 | } 42 | 43 | /** 44 | * Bus indicates the type of disk device to emulate. supported values: virtio, sata, scsi. 45 | * @return bus 46 | **/ 47 | @ApiModelProperty(value = "Bus indicates the type of disk device to emulate. supported values: virtio, sata, scsi.") 48 | public String getBus() { 49 | return bus; 50 | } 51 | 52 | public void setBus(String bus) { 53 | this.bus = bus; 54 | } 55 | 56 | public V1LunTarget readonly(Boolean readonly) { 57 | this.readonly = readonly; 58 | return this; 59 | } 60 | 61 | /** 62 | * ReadOnly. Defaults to false. 63 | * @return readonly 64 | **/ 65 | @ApiModelProperty(value = "ReadOnly. Defaults to false.") 66 | public Boolean isReadonly() { 67 | return readonly; 68 | } 69 | 70 | public void setReadonly(Boolean readonly) { 71 | this.readonly = readonly; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1LunTarget v1LunTarget = (V1LunTarget) o; 84 | return Objects.equals(this.bus, v1LunTarget.bus) && 85 | Objects.equals(this.readonly, v1LunTarget.readonly); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(bus, readonly); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1LunTarget {\n"); 98 | 99 | sb.append(" bus: ").append(toIndentedString(bus)).append("\n"); 100 | sb.append(" readonly: ").append(toIndentedString(readonly)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Machine.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1Machine 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1Machine { 32 | @SerializedName("type") 33 | private String type = null; 34 | 35 | public V1Machine type(String type) { 36 | this.type = type; 37 | return this; 38 | } 39 | 40 | /** 41 | * QEMU machine type is the actual chipset of the VirtualMachineInstance. 42 | * @return type 43 | **/ 44 | @ApiModelProperty(required = true, value = "QEMU machine type is the actual chipset of the VirtualMachineInstance.") 45 | public String getType() { 46 | return type; 47 | } 48 | 49 | public void setType(String type) { 50 | this.type = type; 51 | } 52 | 53 | 54 | @Override 55 | public boolean equals(java.lang.Object o) { 56 | if (this == o) { 57 | return true; 58 | } 59 | if (o == null || getClass() != o.getClass()) { 60 | return false; 61 | } 62 | V1Machine v1Machine = (V1Machine) o; 63 | return Objects.equals(this.type, v1Machine.type); 64 | } 65 | 66 | @Override 67 | public int hashCode() { 68 | return Objects.hash(type); 69 | } 70 | 71 | 72 | @Override 73 | public String toString() { 74 | StringBuilder sb = new StringBuilder(); 75 | sb.append("class V1Machine {\n"); 76 | 77 | sb.append(" type: ").append(toIndentedString(type)).append("\n"); 78 | sb.append("}"); 79 | return sb.toString(); 80 | } 81 | 82 | /** 83 | * Convert the given object to string with each line indented by 4 spaces 84 | * (except the first line). 85 | */ 86 | private String toIndentedString(java.lang.Object o) { 87 | if (o == null) { 88 | return "null"; 89 | } 90 | return o.toString().replace("\n", "\n "); 91 | } 92 | 93 | } 94 | 95 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1MultusNetwork.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * Represents the multus cni network. 29 | */ 30 | @ApiModel(description = "Represents the multus cni network.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1MultusNetwork { 33 | @SerializedName("default") 34 | private Boolean _default = null; 35 | 36 | @SerializedName("networkName") 37 | private String networkName = null; 38 | 39 | public V1MultusNetwork _default(Boolean _default) { 40 | this._default = _default; 41 | return this; 42 | } 43 | 44 | /** 45 | * Select the default network and add it to the multus-cni.io/default-network annotation. 46 | * @return _default 47 | **/ 48 | @ApiModelProperty(value = "Select the default network and add it to the multus-cni.io/default-network annotation.") 49 | public Boolean isDefault() { 50 | return _default; 51 | } 52 | 53 | public void setDefault(Boolean _default) { 54 | this._default = _default; 55 | } 56 | 57 | public V1MultusNetwork networkName(String networkName) { 58 | this.networkName = networkName; 59 | return this; 60 | } 61 | 62 | /** 63 | * References to a NetworkAttachmentDefinition CRD object. Format: <networkName>, <namespace>/<networkName>. If namespace is not specified, VMI namespace is assumed. 64 | * @return networkName 65 | **/ 66 | @ApiModelProperty(required = true, value = "References to a NetworkAttachmentDefinition CRD object. Format: , /. If namespace is not specified, VMI namespace is assumed.") 67 | public String getNetworkName() { 68 | return networkName; 69 | } 70 | 71 | public void setNetworkName(String networkName) { 72 | this.networkName = networkName; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1MultusNetwork v1MultusNetwork = (V1MultusNetwork) o; 85 | return Objects.equals(this._default, v1MultusNetwork._default) && 86 | Objects.equals(this.networkName, v1MultusNetwork.networkName); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(_default, networkName); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1MultusNetwork {\n"); 99 | 100 | sb.append(" _default: ").append(toIndentedString(_default)).append("\n"); 101 | sb.append(" networkName: ").append(toIndentedString(networkName)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1NetworkAttachmentDefinitionSpec.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | 18 | import com.google.gson.annotations.SerializedName; 19 | import io.swagger.annotations.ApiModelProperty; 20 | 21 | /** 22 | * V1NetworkAttachmentDefinitionSpec 23 | */ 24 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2020-02-20T11:28:11.418+02:00") 25 | public class V1NetworkAttachmentDefinitionSpec { 26 | @SerializedName("config") 27 | private String config = null; 28 | 29 | public V1NetworkAttachmentDefinitionSpec config(String config) { 30 | this.config = config; 31 | return this; 32 | } 33 | 34 | /** 35 | * Get config 36 | * @return config 37 | **/ 38 | @ApiModelProperty(required = true, value = "") 39 | public String getConfig() { 40 | return config; 41 | } 42 | 43 | public void setConfig(String config) { 44 | this.config = config; 45 | } 46 | 47 | 48 | @Override 49 | public boolean equals(java.lang.Object o) { 50 | if (this == o) { 51 | return true; 52 | } 53 | if (o == null || getClass() != o.getClass()) { 54 | return false; 55 | } 56 | V1NetworkAttachmentDefinitionSpec v1NetworkAttachmentDefinitionSpec = (V1NetworkAttachmentDefinitionSpec) o; 57 | return Objects.equals(this.config, v1NetworkAttachmentDefinitionSpec.config); 58 | } 59 | 60 | @Override 61 | public int hashCode() { 62 | return Objects.hash(config); 63 | } 64 | 65 | 66 | @Override 67 | public String toString() { 68 | StringBuilder sb = new StringBuilder(); 69 | sb.append("class V1NetworkAttachmentDefinitionSpec {\n"); 70 | 71 | sb.append(" config: ").append(toIndentedString(config)).append("\n"); 72 | sb.append("}"); 73 | return sb.toString(); 74 | } 75 | 76 | /** 77 | * Convert the given object to string with each line indented by 4 spaces 78 | * (except the first line). 79 | */ 80 | private String toIndentedString(java.lang.Object o) { 81 | if (o == null) { 82 | return "null"; 83 | } 84 | return o.toString().replace("\n", "\n "); 85 | } 86 | 87 | } 88 | 89 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1NodeSelector.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import java.util.ArrayList; 27 | import java.util.List; 28 | import kubevirt.io.V1NodeSelectorTerm; 29 | 30 | /** 31 | * A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms. 32 | */ 33 | @ApiModel(description = "A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms.") 34 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 35 | public class V1NodeSelector { 36 | @SerializedName("nodeSelectorTerms") 37 | private List nodeSelectorTerms = new ArrayList<>(); 38 | 39 | public V1NodeSelector nodeSelectorTerms(List nodeSelectorTerms) { 40 | this.nodeSelectorTerms = nodeSelectorTerms; 41 | return this; 42 | } 43 | 44 | public V1NodeSelector addNodeSelectorTermsItem(V1NodeSelectorTerm nodeSelectorTermsItem) { 45 | this.nodeSelectorTerms.add(nodeSelectorTermsItem); 46 | return this; 47 | } 48 | 49 | /** 50 | * Required. A list of node selector terms. The terms are ORed. 51 | * @return nodeSelectorTerms 52 | **/ 53 | @ApiModelProperty(required = true, value = "Required. A list of node selector terms. The terms are ORed.") 54 | public List getNodeSelectorTerms() { 55 | return nodeSelectorTerms; 56 | } 57 | 58 | public void setNodeSelectorTerms(List nodeSelectorTerms) { 59 | this.nodeSelectorTerms = nodeSelectorTerms; 60 | } 61 | 62 | 63 | @Override 64 | public boolean equals(java.lang.Object o) { 65 | if (this == o) { 66 | return true; 67 | } 68 | if (o == null || getClass() != o.getClass()) { 69 | return false; 70 | } 71 | V1NodeSelector v1NodeSelector = (V1NodeSelector) o; 72 | return Objects.equals(this.nodeSelectorTerms, v1NodeSelector.nodeSelectorTerms); 73 | } 74 | 75 | @Override 76 | public int hashCode() { 77 | return Objects.hash(nodeSelectorTerms); 78 | } 79 | 80 | 81 | @Override 82 | public String toString() { 83 | StringBuilder sb = new StringBuilder(); 84 | sb.append("class V1NodeSelector {\n"); 85 | 86 | sb.append(" nodeSelectorTerms: ").append(toIndentedString(nodeSelectorTerms)).append("\n"); 87 | sb.append("}"); 88 | return sb.toString(); 89 | } 90 | 91 | /** 92 | * Convert the given object to string with each line indented by 4 spaces 93 | * (except the first line). 94 | */ 95 | private String toIndentedString(java.lang.Object o) { 96 | if (o == null) { 97 | return "null"; 98 | } 99 | return o.toString().replace("\n", "\n "); 100 | } 101 | 102 | } 103 | 104 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1PITTimer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1PITTimer 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1PITTimer { 32 | @SerializedName("present") 33 | private Boolean present = null; 34 | 35 | @SerializedName("tickPolicy") 36 | private String tickPolicy = null; 37 | 38 | public V1PITTimer present(Boolean present) { 39 | this.present = present; 40 | return this; 41 | } 42 | 43 | /** 44 | * Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional 45 | * @return present 46 | **/ 47 | @ApiModelProperty(value = "Enabled set to false makes sure that the machine type or a preset can't add the timer. Defaults to true. +optional") 48 | public Boolean isPresent() { 49 | return present; 50 | } 51 | 52 | public void setPresent(Boolean present) { 53 | this.present = present; 54 | } 55 | 56 | public V1PITTimer tickPolicy(String tickPolicy) { 57 | this.tickPolicy = tickPolicy; 58 | return this; 59 | } 60 | 61 | /** 62 | * TickPolicy determines what happens when QEMU misses a deadline for injecting a tick to the guest. One of \"delay\", \"catchup\", \"discard\". 63 | * @return tickPolicy 64 | **/ 65 | @ApiModelProperty(value = "TickPolicy determines what happens when QEMU misses a deadline for injecting a tick to the guest. One of \"delay\", \"catchup\", \"discard\".") 66 | public String getTickPolicy() { 67 | return tickPolicy; 68 | } 69 | 70 | public void setTickPolicy(String tickPolicy) { 71 | this.tickPolicy = tickPolicy; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1PITTimer v1PITTimer = (V1PITTimer) o; 84 | return Objects.equals(this.present, v1PITTimer.present) && 85 | Objects.equals(this.tickPolicy, v1PITTimer.tickPolicy); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(present, tickPolicy); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1PITTimer {\n"); 98 | 99 | sb.append(" present: ").append(toIndentedString(present)).append("\n"); 100 | sb.append(" tickPolicy: ").append(toIndentedString(tickPolicy)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Patch.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import io.swagger.annotations.ApiModel; 19 | 20 | /** 21 | * Patch is provided to give a concrete name and type to the Kubernetes PATCH request body. 22 | */ 23 | @ApiModel(description = "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.") 24 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 25 | public class V1Patch { 26 | 27 | @Override 28 | public boolean equals(java.lang.Object o) { 29 | if (this == o) { 30 | return true; 31 | } 32 | if (o == null || getClass() != o.getClass()) { 33 | return false; 34 | } 35 | return true; 36 | } 37 | 38 | @Override 39 | public int hashCode() { 40 | return Objects.hash(); 41 | } 42 | 43 | 44 | @Override 45 | public String toString() { 46 | StringBuilder sb = new StringBuilder(); 47 | sb.append("class V1Patch {\n"); 48 | 49 | sb.append("}"); 50 | return sb.toString(); 51 | } 52 | 53 | /** 54 | * Convert the given object to string with each line indented by 4 spaces 55 | * (except the first line). 56 | */ 57 | private String toIndentedString(java.lang.Object o) { 58 | if (o == null) { 59 | return "null"; 60 | } 61 | return o.toString().replace("\n", "\n "); 62 | } 63 | 64 | } 65 | 66 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1PodDNSConfigOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * PodDNSConfigOption defines DNS resolver options of a pod. 29 | */ 30 | @ApiModel(description = "PodDNSConfigOption defines DNS resolver options of a pod.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1PodDNSConfigOption { 33 | @SerializedName("name") 34 | private String name = null; 35 | 36 | @SerializedName("value") 37 | private String value = null; 38 | 39 | public V1PodDNSConfigOption name(String name) { 40 | this.name = name; 41 | return this; 42 | } 43 | 44 | /** 45 | * Required. 46 | * @return name 47 | **/ 48 | @ApiModelProperty(value = "Required.") 49 | public String getName() { 50 | return name; 51 | } 52 | 53 | public void setName(String name) { 54 | this.name = name; 55 | } 56 | 57 | public V1PodDNSConfigOption value(String value) { 58 | this.value = value; 59 | return this; 60 | } 61 | 62 | /** 63 | * Get value 64 | * @return value 65 | **/ 66 | @ApiModelProperty(value = "") 67 | public String getValue() { 68 | return value; 69 | } 70 | 71 | public void setValue(String value) { 72 | this.value = value; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1PodDNSConfigOption v1PodDNSConfigOption = (V1PodDNSConfigOption) o; 85 | return Objects.equals(this.name, v1PodDNSConfigOption.name) && 86 | Objects.equals(this.value, v1PodDNSConfigOption.value); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(name, value); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1PodDNSConfigOption {\n"); 99 | 100 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 101 | sb.append(" value: ").append(toIndentedString(value)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1PodNetwork.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * Represents the stock pod network interface. 29 | */ 30 | @ApiModel(description = "Represents the stock pod network interface.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1PodNetwork { 33 | @SerializedName("vmNetworkCIDR") 34 | private String vmNetworkCIDR = null; 35 | 36 | public V1PodNetwork vmNetworkCIDR(String vmNetworkCIDR) { 37 | this.vmNetworkCIDR = vmNetworkCIDR; 38 | return this; 39 | } 40 | 41 | /** 42 | * CIDR for vm network. Default 10.0.2.0/24 if not specified. 43 | * @return vmNetworkCIDR 44 | **/ 45 | @ApiModelProperty(value = "CIDR for vm network. Default 10.0.2.0/24 if not specified.") 46 | public String getVmNetworkCIDR() { 47 | return vmNetworkCIDR; 48 | } 49 | 50 | public void setVmNetworkCIDR(String vmNetworkCIDR) { 51 | this.vmNetworkCIDR = vmNetworkCIDR; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1PodNetwork v1PodNetwork = (V1PodNetwork) o; 64 | return Objects.equals(this.vmNetworkCIDR, v1PodNetwork.vmNetworkCIDR); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(vmNetworkCIDR); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1PodNetwork {\n"); 77 | 78 | sb.append(" vmNetworkCIDR: ").append(toIndentedString(vmNetworkCIDR)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Preconditions.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import kubevirt.io.TypesUID; 27 | 28 | /** 29 | * Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out. 30 | */ 31 | @ApiModel(description = "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.") 32 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 33 | public class V1Preconditions { 34 | @SerializedName("uid") 35 | private TypesUID uid = null; 36 | 37 | public V1Preconditions uid(TypesUID uid) { 38 | this.uid = uid; 39 | return this; 40 | } 41 | 42 | /** 43 | * Specifies the target UID. 44 | * @return uid 45 | **/ 46 | @ApiModelProperty(value = "Specifies the target UID.") 47 | public TypesUID getUid() { 48 | return uid; 49 | } 50 | 51 | public void setUid(TypesUID uid) { 52 | this.uid = uid; 53 | } 54 | 55 | 56 | @Override 57 | public boolean equals(java.lang.Object o) { 58 | if (this == o) { 59 | return true; 60 | } 61 | if (o == null || getClass() != o.getClass()) { 62 | return false; 63 | } 64 | V1Preconditions v1Preconditions = (V1Preconditions) o; 65 | return Objects.equals(this.uid, v1Preconditions.uid); 66 | } 67 | 68 | @Override 69 | public int hashCode() { 70 | return Objects.hash(uid); 71 | } 72 | 73 | 74 | @Override 75 | public String toString() { 76 | StringBuilder sb = new StringBuilder(); 77 | sb.append("class V1Preconditions {\n"); 78 | 79 | sb.append(" uid: ").append(toIndentedString(uid)).append("\n"); 80 | sb.append("}"); 81 | return sb.toString(); 82 | } 83 | 84 | /** 85 | * Convert the given object to string with each line indented by 4 spaces 86 | * (except the first line). 87 | */ 88 | private String toIndentedString(java.lang.Object o) { 89 | if (o == null) { 90 | return "null"; 91 | } 92 | return o.toString().replace("\n", "\n "); 93 | } 94 | 95 | } 96 | 97 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Rng.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import io.swagger.annotations.ApiModel; 19 | 20 | /** 21 | * Rng represents the random device passed from host 22 | */ 23 | @ApiModel(description = "Rng represents the random device passed from host") 24 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 25 | public class V1Rng { 26 | 27 | @Override 28 | public boolean equals(java.lang.Object o) { 29 | if (this == o) { 30 | return true; 31 | } 32 | if (o == null || getClass() != o.getClass()) { 33 | return false; 34 | } 35 | return true; 36 | } 37 | 38 | @Override 39 | public int hashCode() { 40 | return Objects.hash(); 41 | } 42 | 43 | 44 | @Override 45 | public String toString() { 46 | StringBuilder sb = new StringBuilder(); 47 | sb.append("class V1Rng {\n"); 48 | 49 | sb.append("}"); 50 | return sb.toString(); 51 | } 52 | 53 | /** 54 | * Convert the given object to string with each line indented by 4 spaces 55 | * (except the first line). 56 | */ 57 | private String toIndentedString(java.lang.Object o) { 58 | if (o == null) { 59 | return "null"; 60 | } 61 | return o.toString().replace("\n", "\n "); 62 | } 63 | 64 | } 65 | 66 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1RootPaths.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import java.util.ArrayList; 27 | import java.util.List; 28 | 29 | /** 30 | * RootPaths lists the paths available at root. For example: \"/healthz\", \"/apis\". 31 | */ 32 | @ApiModel(description = "RootPaths lists the paths available at root. For example: \"/healthz\", \"/apis\".") 33 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 34 | public class V1RootPaths { 35 | @SerializedName("paths") 36 | private List paths = new ArrayList<>(); 37 | 38 | public V1RootPaths paths(List paths) { 39 | this.paths = paths; 40 | return this; 41 | } 42 | 43 | public V1RootPaths addPathsItem(String pathsItem) { 44 | this.paths.add(pathsItem); 45 | return this; 46 | } 47 | 48 | /** 49 | * paths are the paths available at root. 50 | * @return paths 51 | **/ 52 | @ApiModelProperty(required = true, value = "paths are the paths available at root.") 53 | public List getPaths() { 54 | return paths; 55 | } 56 | 57 | public void setPaths(List paths) { 58 | this.paths = paths; 59 | } 60 | 61 | 62 | @Override 63 | public boolean equals(java.lang.Object o) { 64 | if (this == o) { 65 | return true; 66 | } 67 | if (o == null || getClass() != o.getClass()) { 68 | return false; 69 | } 70 | V1RootPaths v1RootPaths = (V1RootPaths) o; 71 | return Objects.equals(this.paths, v1RootPaths.paths); 72 | } 73 | 74 | @Override 75 | public int hashCode() { 76 | return Objects.hash(paths); 77 | } 78 | 79 | 80 | @Override 81 | public String toString() { 82 | StringBuilder sb = new StringBuilder(); 83 | sb.append("class V1RootPaths {\n"); 84 | 85 | sb.append(" paths: ").append(toIndentedString(paths)).append("\n"); 86 | sb.append("}"); 87 | return sb.toString(); 88 | } 89 | 90 | /** 91 | * Convert the given object to string with each line indented by 4 spaces 92 | * (except the first line). 93 | */ 94 | private String toIndentedString(java.lang.Object o) { 95 | if (o == null) { 96 | return "null"; 97 | } 98 | return o.toString().replace("\n", "\n "); 99 | } 100 | 101 | } 102 | 103 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1SecretVolumeSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * SecretVolumeSource adapts a Secret into a volume. 29 | */ 30 | @ApiModel(description = "SecretVolumeSource adapts a Secret into a volume.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1SecretVolumeSource { 33 | @SerializedName("optional") 34 | private Boolean optional = null; 35 | 36 | @SerializedName("secretName") 37 | private String secretName = null; 38 | 39 | public V1SecretVolumeSource optional(Boolean optional) { 40 | this.optional = optional; 41 | return this; 42 | } 43 | 44 | /** 45 | * Specify whether the Secret or it's keys must be defined +optional 46 | * @return optional 47 | **/ 48 | @ApiModelProperty(value = "Specify whether the Secret or it's keys must be defined +optional") 49 | public Boolean isOptional() { 50 | return optional; 51 | } 52 | 53 | public void setOptional(Boolean optional) { 54 | this.optional = optional; 55 | } 56 | 57 | public V1SecretVolumeSource secretName(String secretName) { 58 | this.secretName = secretName; 59 | return this; 60 | } 61 | 62 | /** 63 | * Name of the secret in the pod's namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret +optional 64 | * @return secretName 65 | **/ 66 | @ApiModelProperty(value = "Name of the secret in the pod's namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret +optional") 67 | public String getSecretName() { 68 | return secretName; 69 | } 70 | 71 | public void setSecretName(String secretName) { 72 | this.secretName = secretName; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1SecretVolumeSource v1SecretVolumeSource = (V1SecretVolumeSource) o; 85 | return Objects.equals(this.optional, v1SecretVolumeSource.optional) && 86 | Objects.equals(this.secretName, v1SecretVolumeSource.secretName); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(optional, secretName); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1SecretVolumeSource {\n"); 99 | 100 | sb.append(" optional: ").append(toIndentedString(optional)).append("\n"); 101 | sb.append(" secretName: ").append(toIndentedString(secretName)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1ServiceAccountVolumeSource.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * ServiceAccountVolumeSource adapts a ServiceAccount into a volume. 29 | */ 30 | @ApiModel(description = "ServiceAccountVolumeSource adapts a ServiceAccount into a volume.") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1ServiceAccountVolumeSource { 33 | @SerializedName("serviceAccountName") 34 | private String serviceAccountName = null; 35 | 36 | public V1ServiceAccountVolumeSource serviceAccountName(String serviceAccountName) { 37 | this.serviceAccountName = serviceAccountName; 38 | return this; 39 | } 40 | 41 | /** 42 | * Name of the service account in the pod's namespace to use. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ 43 | * @return serviceAccountName 44 | **/ 45 | @ApiModelProperty(value = "Name of the service account in the pod's namespace to use. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/") 46 | public String getServiceAccountName() { 47 | return serviceAccountName; 48 | } 49 | 50 | public void setServiceAccountName(String serviceAccountName) { 51 | this.serviceAccountName = serviceAccountName; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1ServiceAccountVolumeSource v1ServiceAccountVolumeSource = (V1ServiceAccountVolumeSource) o; 64 | return Objects.equals(this.serviceAccountName, v1ServiceAccountVolumeSource.serviceAccountName); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(serviceAccountName); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1ServiceAccountVolumeSource {\n"); 77 | 78 | sb.append(" serviceAccountName: ").append(toIndentedString(serviceAccountName)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1TCPSocketAction.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * TCPSocketAction describes an action based on opening a socket 29 | */ 30 | @ApiModel(description = "TCPSocketAction describes an action based on opening a socket") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1TCPSocketAction { 33 | @SerializedName("host") 34 | private String host = null; 35 | 36 | public V1TCPSocketAction host(String host) { 37 | this.host = host; 38 | return this; 39 | } 40 | 41 | /** 42 | * Optional: Host name to connect to, defaults to the pod IP. 43 | * @return host 44 | **/ 45 | @ApiModelProperty(value = "Optional: Host name to connect to, defaults to the pod IP.") 46 | public String getHost() { 47 | return host; 48 | } 49 | 50 | public void setHost(String host) { 51 | this.host = host; 52 | } 53 | 54 | 55 | @Override 56 | public boolean equals(java.lang.Object o) { 57 | if (this == o) { 58 | return true; 59 | } 60 | if (o == null || getClass() != o.getClass()) { 61 | return false; 62 | } 63 | V1TCPSocketAction v1TCPSocketAction = (V1TCPSocketAction) o; 64 | return Objects.equals(this.host, v1TCPSocketAction.host); 65 | } 66 | 67 | @Override 68 | public int hashCode() { 69 | return Objects.hash(host); 70 | } 71 | 72 | 73 | @Override 74 | public String toString() { 75 | StringBuilder sb = new StringBuilder(); 76 | sb.append("class V1TCPSocketAction {\n"); 77 | 78 | sb.append(" host: ").append(toIndentedString(host)).append("\n"); 79 | sb.append("}"); 80 | return sb.toString(); 81 | } 82 | 83 | /** 84 | * Convert the given object to string with each line indented by 4 spaces 85 | * (except the first line). 86 | */ 87 | private String toIndentedString(java.lang.Object o) { 88 | if (o == null) { 89 | return "null"; 90 | } 91 | return o.toString().replace("\n", "\n "); 92 | } 93 | 94 | } 95 | 96 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1VirtualMachineInstanceMigrationSpec.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1VirtualMachineInstanceMigrationSpec 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1VirtualMachineInstanceMigrationSpec { 32 | @SerializedName("vmiName") 33 | private String vmiName = null; 34 | 35 | public V1VirtualMachineInstanceMigrationSpec vmiName(String vmiName) { 36 | this.vmiName = vmiName; 37 | return this; 38 | } 39 | 40 | /** 41 | * The name of the VMI to perform the migration on. VMI must exist in the migration objects namespace 42 | * @return vmiName 43 | **/ 44 | @ApiModelProperty(value = "The name of the VMI to perform the migration on. VMI must exist in the migration objects namespace") 45 | public String getVmiName() { 46 | return vmiName; 47 | } 48 | 49 | public void setVmiName(String vmiName) { 50 | this.vmiName = vmiName; 51 | } 52 | 53 | 54 | @Override 55 | public boolean equals(java.lang.Object o) { 56 | if (this == o) { 57 | return true; 58 | } 59 | if (o == null || getClass() != o.getClass()) { 60 | return false; 61 | } 62 | V1VirtualMachineInstanceMigrationSpec v1VirtualMachineInstanceMigrationSpec = (V1VirtualMachineInstanceMigrationSpec) o; 63 | return Objects.equals(this.vmiName, v1VirtualMachineInstanceMigrationSpec.vmiName); 64 | } 65 | 66 | @Override 67 | public int hashCode() { 68 | return Objects.hash(vmiName); 69 | } 70 | 71 | 72 | @Override 73 | public String toString() { 74 | StringBuilder sb = new StringBuilder(); 75 | sb.append("class V1VirtualMachineInstanceMigrationSpec {\n"); 76 | 77 | sb.append(" vmiName: ").append(toIndentedString(vmiName)).append("\n"); 78 | sb.append("}"); 79 | return sb.toString(); 80 | } 81 | 82 | /** 83 | * Convert the given object to string with each line indented by 4 spaces 84 | * (except the first line). 85 | */ 86 | private String toIndentedString(java.lang.Object o) { 87 | if (o == null) { 88 | return "null"; 89 | } 90 | return o.toString().replace("\n", "\n "); 91 | } 92 | 93 | } 94 | 95 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1VirtualMachineInstancePresetSpec.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import kubevirt.io.V1DomainSpec; 27 | import kubevirt.io.V1LabelSelector; 28 | 29 | /** 30 | * V1VirtualMachineInstancePresetSpec 31 | */ 32 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 33 | public class V1VirtualMachineInstancePresetSpec { 34 | @SerializedName("domain") 35 | private V1DomainSpec domain = null; 36 | 37 | @SerializedName("selector") 38 | private V1LabelSelector selector = null; 39 | 40 | public V1VirtualMachineInstancePresetSpec domain(V1DomainSpec domain) { 41 | this.domain = domain; 42 | return this; 43 | } 44 | 45 | /** 46 | * Domain is the same object type as contained in VirtualMachineInstanceSpec 47 | * @return domain 48 | **/ 49 | @ApiModelProperty(value = "Domain is the same object type as contained in VirtualMachineInstanceSpec") 50 | public V1DomainSpec getDomain() { 51 | return domain; 52 | } 53 | 54 | public void setDomain(V1DomainSpec domain) { 55 | this.domain = domain; 56 | } 57 | 58 | public V1VirtualMachineInstancePresetSpec selector(V1LabelSelector selector) { 59 | this.selector = selector; 60 | return this; 61 | } 62 | 63 | /** 64 | * Selector is a label query over a set of VMIs. Required. 65 | * @return selector 66 | **/ 67 | @ApiModelProperty(required = true, value = "Selector is a label query over a set of VMIs. Required.") 68 | public V1LabelSelector getSelector() { 69 | return selector; 70 | } 71 | 72 | public void setSelector(V1LabelSelector selector) { 73 | this.selector = selector; 74 | } 75 | 76 | 77 | @Override 78 | public boolean equals(java.lang.Object o) { 79 | if (this == o) { 80 | return true; 81 | } 82 | if (o == null || getClass() != o.getClass()) { 83 | return false; 84 | } 85 | V1VirtualMachineInstancePresetSpec v1VirtualMachineInstancePresetSpec = (V1VirtualMachineInstancePresetSpec) o; 86 | return Objects.equals(this.domain, v1VirtualMachineInstancePresetSpec.domain) && 87 | Objects.equals(this.selector, v1VirtualMachineInstancePresetSpec.selector); 88 | } 89 | 90 | @Override 91 | public int hashCode() { 92 | return Objects.hash(domain, selector); 93 | } 94 | 95 | 96 | @Override 97 | public String toString() { 98 | StringBuilder sb = new StringBuilder(); 99 | sb.append("class V1VirtualMachineInstancePresetSpec {\n"); 100 | 101 | sb.append(" domain: ").append(toIndentedString(domain)).append("\n"); 102 | sb.append(" selector: ").append(toIndentedString(selector)).append("\n"); 103 | sb.append("}"); 104 | return sb.toString(); 105 | } 106 | 107 | /** 108 | * Convert the given object to string with each line indented by 4 spaces 109 | * (except the first line). 110 | */ 111 | private String toIndentedString(java.lang.Object o) { 112 | if (o == null) { 113 | return "null"; 114 | } 115 | return o.toString().replace("\n", "\n "); 116 | } 117 | 118 | } 119 | 120 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1VirtualMachineInstanceTemplateSpec.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | 24 | import io.kubernetes.client.models.V1ObjectMeta; 25 | import io.swagger.annotations.ApiModel; 26 | import io.swagger.annotations.ApiModelProperty; 27 | import java.io.IOException; 28 | import kubevirt.io.V1VirtualMachineInstanceSpec; 29 | 30 | /** 31 | * V1VirtualMachineInstanceTemplateSpec 32 | */ 33 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 34 | public class V1VirtualMachineInstanceTemplateSpec { 35 | @SerializedName("metadata") 36 | private V1ObjectMeta metadata = null; 37 | 38 | @SerializedName("spec") 39 | private V1VirtualMachineInstanceSpec spec = null; 40 | 41 | public V1VirtualMachineInstanceTemplateSpec metadata(V1ObjectMeta metadata) { 42 | this.metadata = metadata; 43 | return this; 44 | } 45 | 46 | /** 47 | * Get metadata 48 | * @return metadata 49 | **/ 50 | @ApiModelProperty(value = "") 51 | public V1ObjectMeta getMetadata() { 52 | return metadata; 53 | } 54 | 55 | public void setMetadata(V1ObjectMeta metadata) { 56 | this.metadata = metadata; 57 | } 58 | 59 | public V1VirtualMachineInstanceTemplateSpec spec(V1VirtualMachineInstanceSpec spec) { 60 | this.spec = spec; 61 | return this; 62 | } 63 | 64 | /** 65 | * VirtualMachineInstance Spec contains the VirtualMachineInstance specification. 66 | * @return spec 67 | **/ 68 | @ApiModelProperty(value = "VirtualMachineInstance Spec contains the VirtualMachineInstance specification.") 69 | public V1VirtualMachineInstanceSpec getSpec() { 70 | return spec; 71 | } 72 | 73 | public void setSpec(V1VirtualMachineInstanceSpec spec) { 74 | this.spec = spec; 75 | } 76 | 77 | 78 | @Override 79 | public boolean equals(java.lang.Object o) { 80 | if (this == o) { 81 | return true; 82 | } 83 | if (o == null || getClass() != o.getClass()) { 84 | return false; 85 | } 86 | V1VirtualMachineInstanceTemplateSpec v1VirtualMachineInstanceTemplateSpec = (V1VirtualMachineInstanceTemplateSpec) o; 87 | return Objects.equals(this.metadata, v1VirtualMachineInstanceTemplateSpec.metadata) && 88 | Objects.equals(this.spec, v1VirtualMachineInstanceTemplateSpec.spec); 89 | } 90 | 91 | @Override 92 | public int hashCode() { 93 | return Objects.hash(metadata, spec); 94 | } 95 | 96 | 97 | @Override 98 | public String toString() { 99 | StringBuilder sb = new StringBuilder(); 100 | sb.append("class V1VirtualMachineInstanceTemplateSpec {\n"); 101 | 102 | sb.append(" metadata: ").append(toIndentedString(metadata)).append("\n"); 103 | sb.append(" spec: ").append(toIndentedString(spec)).append("\n"); 104 | sb.append("}"); 105 | return sb.toString(); 106 | } 107 | 108 | /** 109 | * Convert the given object to string with each line indented by 4 spaces 110 | * (except the first line). 111 | */ 112 | private String toIndentedString(java.lang.Object o) { 113 | if (o == null) { 114 | return "null"; 115 | } 116 | return o.toString().replace("\n", "\n "); 117 | } 118 | 119 | } 120 | 121 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1VirtualMachineStateChangeRequest.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import kubevirt.io.TypesUID; 27 | 28 | /** 29 | * V1VirtualMachineStateChangeRequest 30 | */ 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1VirtualMachineStateChangeRequest { 33 | @SerializedName("action") 34 | private String action = null; 35 | 36 | @SerializedName("uid") 37 | private TypesUID uid = null; 38 | 39 | public V1VirtualMachineStateChangeRequest action(String action) { 40 | this.action = action; 41 | return this; 42 | } 43 | 44 | /** 45 | * Indicates the type of action that is requested. e.g. Start or Stop 46 | * @return action 47 | **/ 48 | @ApiModelProperty(required = true, value = "Indicates the type of action that is requested. e.g. Start or Stop") 49 | public String getAction() { 50 | return action; 51 | } 52 | 53 | public void setAction(String action) { 54 | this.action = action; 55 | } 56 | 57 | public V1VirtualMachineStateChangeRequest uid(TypesUID uid) { 58 | this.uid = uid; 59 | return this; 60 | } 61 | 62 | /** 63 | * Indicates the UUID of an existing Virtual Machine Instance that this change request applies to -- if applicable 64 | * @return uid 65 | **/ 66 | @ApiModelProperty(value = "Indicates the UUID of an existing Virtual Machine Instance that this change request applies to -- if applicable") 67 | public TypesUID getUid() { 68 | return uid; 69 | } 70 | 71 | public void setUid(TypesUID uid) { 72 | this.uid = uid; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1VirtualMachineStateChangeRequest v1VirtualMachineStateChangeRequest = (V1VirtualMachineStateChangeRequest) o; 85 | return Objects.equals(this.action, v1VirtualMachineStateChangeRequest.action) && 86 | Objects.equals(this.uid, v1VirtualMachineStateChangeRequest.uid); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(action, uid); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1VirtualMachineStateChangeRequest {\n"); 99 | 100 | sb.append(" action: ").append(toIndentedString(action)).append("\n"); 101 | sb.append(" uid: ").append(toIndentedString(uid)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1WatchEvent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * V1WatchEvent 29 | */ 30 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 31 | public class V1WatchEvent { 32 | @SerializedName("object") 33 | private String object = null; 34 | 35 | @SerializedName("type") 36 | private String type = null; 37 | 38 | public V1WatchEvent object(String object) { 39 | this.object = object; 40 | return this; 41 | } 42 | 43 | /** 44 | * Get object 45 | * @return object 46 | **/ 47 | @ApiModelProperty(required = true, value = "") 48 | public String getObject() { 49 | return object; 50 | } 51 | 52 | public void setObject(String object) { 53 | this.object = object; 54 | } 55 | 56 | public V1WatchEvent type(String type) { 57 | this.type = type; 58 | return this; 59 | } 60 | 61 | /** 62 | * Get type 63 | * @return type 64 | **/ 65 | @ApiModelProperty(required = true, value = "") 66 | public String getType() { 67 | return type; 68 | } 69 | 70 | public void setType(String type) { 71 | this.type = type; 72 | } 73 | 74 | 75 | @Override 76 | public boolean equals(java.lang.Object o) { 77 | if (this == o) { 78 | return true; 79 | } 80 | if (o == null || getClass() != o.getClass()) { 81 | return false; 82 | } 83 | V1WatchEvent v1WatchEvent = (V1WatchEvent) o; 84 | return Objects.equals(this.object, v1WatchEvent.object) && 85 | Objects.equals(this.type, v1WatchEvent.type); 86 | } 87 | 88 | @Override 89 | public int hashCode() { 90 | return Objects.hash(object, type); 91 | } 92 | 93 | 94 | @Override 95 | public String toString() { 96 | StringBuilder sb = new StringBuilder(); 97 | sb.append("class V1WatchEvent {\n"); 98 | 99 | sb.append(" object: ").append(toIndentedString(object)).append("\n"); 100 | sb.append(" type: ").append(toIndentedString(type)).append("\n"); 101 | sb.append("}"); 102 | return sb.toString(); 103 | } 104 | 105 | /** 106 | * Convert the given object to string with each line indented by 4 spaces 107 | * (except the first line). 108 | */ 109 | private String toIndentedString(java.lang.Object o) { 110 | if (o == null) { 111 | return "null"; 112 | } 113 | return o.toString().replace("\n", "\n "); 114 | } 115 | 116 | } 117 | 118 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1Watchdog.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | import kubevirt.io.V1I6300ESBWatchdog; 27 | 28 | /** 29 | * Named watchdog device. 30 | */ 31 | @ApiModel(description = "Named watchdog device.") 32 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 33 | public class V1Watchdog { 34 | @SerializedName("i6300esb") 35 | private V1I6300ESBWatchdog i6300esb = null; 36 | 37 | @SerializedName("name") 38 | private String name = null; 39 | 40 | public V1Watchdog i6300esb(V1I6300ESBWatchdog i6300esb) { 41 | this.i6300esb = i6300esb; 42 | return this; 43 | } 44 | 45 | /** 46 | * i6300esb watchdog device. +optional 47 | * @return i6300esb 48 | **/ 49 | @ApiModelProperty(value = "i6300esb watchdog device. +optional") 50 | public V1I6300ESBWatchdog getI6300esb() { 51 | return i6300esb; 52 | } 53 | 54 | public void setI6300esb(V1I6300ESBWatchdog i6300esb) { 55 | this.i6300esb = i6300esb; 56 | } 57 | 58 | public V1Watchdog name(String name) { 59 | this.name = name; 60 | return this; 61 | } 62 | 63 | /** 64 | * Name of the watchdog. 65 | * @return name 66 | **/ 67 | @ApiModelProperty(required = true, value = "Name of the watchdog.") 68 | public String getName() { 69 | return name; 70 | } 71 | 72 | public void setName(String name) { 73 | this.name = name; 74 | } 75 | 76 | 77 | @Override 78 | public boolean equals(java.lang.Object o) { 79 | if (this == o) { 80 | return true; 81 | } 82 | if (o == null || getClass() != o.getClass()) { 83 | return false; 84 | } 85 | V1Watchdog v1Watchdog = (V1Watchdog) o; 86 | return Objects.equals(this.i6300esb, v1Watchdog.i6300esb) && 87 | Objects.equals(this.name, v1Watchdog.name); 88 | } 89 | 90 | @Override 91 | public int hashCode() { 92 | return Objects.hash(i6300esb, name); 93 | } 94 | 95 | 96 | @Override 97 | public String toString() { 98 | StringBuilder sb = new StringBuilder(); 99 | sb.append("class V1Watchdog {\n"); 100 | 101 | sb.append(" i6300esb: ").append(toIndentedString(i6300esb)).append("\n"); 102 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 103 | sb.append("}"); 104 | return sb.toString(); 105 | } 106 | 107 | /** 108 | * Convert the given object to string with each line indented by 4 spaces 109 | * (except the first line). 110 | */ 111 | private String toIndentedString(java.lang.Object o) { 112 | if (o == null) { 113 | return "null"; 114 | } 115 | return o.toString().replace("\n", "\n "); 116 | } 117 | 118 | } 119 | 120 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1alpha1DataVolumeBlankImage.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import io.swagger.annotations.ApiModel; 19 | 20 | /** 21 | * DataVolumeBlankImage provides the parameters to create a new raw blank image for the PVC 22 | */ 23 | @ApiModel(description = "DataVolumeBlankImage provides the parameters to create a new raw blank image for the PVC") 24 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 25 | public class V1alpha1DataVolumeBlankImage { 26 | 27 | @Override 28 | public boolean equals(java.lang.Object o) { 29 | if (this == o) { 30 | return true; 31 | } 32 | if (o == null || getClass() != o.getClass()) { 33 | return false; 34 | } 35 | return true; 36 | } 37 | 38 | @Override 39 | public int hashCode() { 40 | return Objects.hash(); 41 | } 42 | 43 | 44 | @Override 45 | public String toString() { 46 | StringBuilder sb = new StringBuilder(); 47 | sb.append("class V1alpha1DataVolumeBlankImage {\n"); 48 | 49 | sb.append("}"); 50 | return sb.toString(); 51 | } 52 | 53 | /** 54 | * Convert the given object to string with each line indented by 4 spaces 55 | * (except the first line). 56 | */ 57 | private String toIndentedString(java.lang.Object o) { 58 | if (o == null) { 59 | return "null"; 60 | } 61 | return o.toString().replace("\n", "\n "); 62 | } 63 | 64 | } 65 | 66 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1alpha1DataVolumeSourcePVC.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * DataVolumeSourcePVC provides the parameters to create a Data Volume from an existing PVC 29 | */ 30 | @ApiModel(description = "DataVolumeSourcePVC provides the parameters to create a Data Volume from an existing PVC") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1alpha1DataVolumeSourcePVC { 33 | @SerializedName("name") 34 | private String name = null; 35 | 36 | @SerializedName("namespace") 37 | private String namespace = null; 38 | 39 | public V1alpha1DataVolumeSourcePVC name(String name) { 40 | this.name = name; 41 | return this; 42 | } 43 | 44 | /** 45 | * Get name 46 | * @return name 47 | **/ 48 | @ApiModelProperty(value = "") 49 | public String getName() { 50 | return name; 51 | } 52 | 53 | public void setName(String name) { 54 | this.name = name; 55 | } 56 | 57 | public V1alpha1DataVolumeSourcePVC namespace(String namespace) { 58 | this.namespace = namespace; 59 | return this; 60 | } 61 | 62 | /** 63 | * Get namespace 64 | * @return namespace 65 | **/ 66 | @ApiModelProperty(value = "") 67 | public String getNamespace() { 68 | return namespace; 69 | } 70 | 71 | public void setNamespace(String namespace) { 72 | this.namespace = namespace; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1alpha1DataVolumeSourcePVC v1alpha1DataVolumeSourcePVC = (V1alpha1DataVolumeSourcePVC) o; 85 | return Objects.equals(this.name, v1alpha1DataVolumeSourcePVC.name) && 86 | Objects.equals(this.namespace, v1alpha1DataVolumeSourcePVC.namespace); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(name, namespace); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1alpha1DataVolumeSourcePVC {\n"); 99 | 100 | sb.append(" name: ").append(toIndentedString(name)).append("\n"); 101 | sb.append(" namespace: ").append(toIndentedString(namespace)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1alpha1DataVolumeSourceS3.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * DataVolumeSourceS3 provides the parameters to create a Data Volume from an S3 source 29 | */ 30 | @ApiModel(description = "DataVolumeSourceS3 provides the parameters to create a Data Volume from an S3 source") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1alpha1DataVolumeSourceS3 { 33 | @SerializedName("secretRef") 34 | private String secretRef = null; 35 | 36 | @SerializedName("url") 37 | private String url = null; 38 | 39 | public V1alpha1DataVolumeSourceS3 secretRef(String secretRef) { 40 | this.secretRef = secretRef; 41 | return this; 42 | } 43 | 44 | /** 45 | * SecretRef provides the secret reference needed to access the S3 source 46 | * @return secretRef 47 | **/ 48 | @ApiModelProperty(value = "SecretRef provides the secret reference needed to access the S3 source") 49 | public String getSecretRef() { 50 | return secretRef; 51 | } 52 | 53 | public void setSecretRef(String secretRef) { 54 | this.secretRef = secretRef; 55 | } 56 | 57 | public V1alpha1DataVolumeSourceS3 url(String url) { 58 | this.url = url; 59 | return this; 60 | } 61 | 62 | /** 63 | * URL is the url of the S3 source 64 | * @return url 65 | **/ 66 | @ApiModelProperty(value = "URL is the url of the S3 source") 67 | public String getUrl() { 68 | return url; 69 | } 70 | 71 | public void setUrl(String url) { 72 | this.url = url; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1alpha1DataVolumeSourceS3 v1alpha1DataVolumeSourceS3 = (V1alpha1DataVolumeSourceS3) o; 85 | return Objects.equals(this.secretRef, v1alpha1DataVolumeSourceS3.secretRef) && 86 | Objects.equals(this.url, v1alpha1DataVolumeSourceS3.url); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(secretRef, url); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1alpha1DataVolumeSourceS3 {\n"); 99 | 100 | sb.append(" secretRef: ").append(toIndentedString(secretRef)).append("\n"); 101 | sb.append(" url: ").append(toIndentedString(url)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1alpha1DataVolumeSourceUpload.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import io.swagger.annotations.ApiModel; 19 | 20 | /** 21 | * DataVolumeSourceUpload provides the parameters to create a Data Volume by uploading the source 22 | */ 23 | @ApiModel(description = "DataVolumeSourceUpload provides the parameters to create a Data Volume by uploading the source") 24 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 25 | public class V1alpha1DataVolumeSourceUpload { 26 | 27 | @Override 28 | public boolean equals(java.lang.Object o) { 29 | if (this == o) { 30 | return true; 31 | } 32 | if (o == null || getClass() != o.getClass()) { 33 | return false; 34 | } 35 | return true; 36 | } 37 | 38 | @Override 39 | public int hashCode() { 40 | return Objects.hash(); 41 | } 42 | 43 | 44 | @Override 45 | public String toString() { 46 | StringBuilder sb = new StringBuilder(); 47 | sb.append("class V1alpha1DataVolumeSourceUpload {\n"); 48 | 49 | sb.append("}"); 50 | return sb.toString(); 51 | } 52 | 53 | /** 54 | * Convert the given object to string with each line indented by 4 spaces 55 | * (except the first line). 56 | */ 57 | private String toIndentedString(java.lang.Object o) { 58 | if (o == null) { 59 | return "null"; 60 | } 61 | return o.toString().replace("\n", "\n "); 62 | } 63 | 64 | } 65 | 66 | -------------------------------------------------------------------------------- /src/main/java/kubevirt/io/V1alpha1DataVolumeStatus.java: -------------------------------------------------------------------------------- 1 | /* 2 | * KubeVirt API 3 | * This is KubeVirt API an add-on for Kubernetes. 4 | * 5 | * OpenAPI spec version: 1.0.0 6 | * Contact: kubevirt-dev@googlegroups.com 7 | * 8 | * NOTE: This class is auto generated by the swagger code generator program. 9 | * https://github.com/swagger-api/swagger-codegen.git 10 | * Do not edit the class manually. 11 | */ 12 | 13 | 14 | package kubevirt.io; 15 | 16 | import java.util.Objects; 17 | import java.util.Arrays; 18 | import com.google.gson.TypeAdapter; 19 | import com.google.gson.annotations.JsonAdapter; 20 | import com.google.gson.annotations.SerializedName; 21 | import com.google.gson.stream.JsonReader; 22 | import com.google.gson.stream.JsonWriter; 23 | import io.swagger.annotations.ApiModel; 24 | import io.swagger.annotations.ApiModelProperty; 25 | import java.io.IOException; 26 | 27 | /** 28 | * DataVolumeStatus provides the parameters to store the phase of the Data Volume 29 | */ 30 | @ApiModel(description = "DataVolumeStatus provides the parameters to store the phase of the Data Volume") 31 | @javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2019-11-10T14:44:51.030+02:00") 32 | public class V1alpha1DataVolumeStatus { 33 | @SerializedName("phase") 34 | private String phase = null; 35 | 36 | @SerializedName("progress") 37 | private String progress = null; 38 | 39 | public V1alpha1DataVolumeStatus phase(String phase) { 40 | this.phase = phase; 41 | return this; 42 | } 43 | 44 | /** 45 | * Phase is the current phase of the data volume 46 | * @return phase 47 | **/ 48 | @ApiModelProperty(value = "Phase is the current phase of the data volume") 49 | public String getPhase() { 50 | return phase; 51 | } 52 | 53 | public void setPhase(String phase) { 54 | this.phase = phase; 55 | } 56 | 57 | public V1alpha1DataVolumeStatus progress(String progress) { 58 | this.progress = progress; 59 | return this; 60 | } 61 | 62 | /** 63 | * Get progress 64 | * @return progress 65 | **/ 66 | @ApiModelProperty(value = "") 67 | public String getProgress() { 68 | return progress; 69 | } 70 | 71 | public void setProgress(String progress) { 72 | this.progress = progress; 73 | } 74 | 75 | 76 | @Override 77 | public boolean equals(java.lang.Object o) { 78 | if (this == o) { 79 | return true; 80 | } 81 | if (o == null || getClass() != o.getClass()) { 82 | return false; 83 | } 84 | V1alpha1DataVolumeStatus v1alpha1DataVolumeStatus = (V1alpha1DataVolumeStatus) o; 85 | return Objects.equals(this.phase, v1alpha1DataVolumeStatus.phase) && 86 | Objects.equals(this.progress, v1alpha1DataVolumeStatus.progress); 87 | } 88 | 89 | @Override 90 | public int hashCode() { 91 | return Objects.hash(phase, progress); 92 | } 93 | 94 | 95 | @Override 96 | public String toString() { 97 | StringBuilder sb = new StringBuilder(); 98 | sb.append("class V1alpha1DataVolumeStatus {\n"); 99 | 100 | sb.append(" phase: ").append(toIndentedString(phase)).append("\n"); 101 | sb.append(" progress: ").append(toIndentedString(progress)).append("\n"); 102 | sb.append("}"); 103 | return sb.toString(); 104 | } 105 | 106 | /** 107 | * Convert the given object to string with each line indented by 4 spaces 108 | * (except the first line). 109 | */ 110 | private String toIndentedString(java.lang.Object o) { 111 | if (o == null) { 112 | return "null"; 113 | } 114 | return o.toString().replace("\n", "\n "); 115 | } 116 | 117 | } 118 | 119 | -------------------------------------------------------------------------------- /src/main/java/openshift/io/V1RoutePort.java: -------------------------------------------------------------------------------- 1 | package openshift.io; 2 | 3 | import com.google.gson.annotations.SerializedName; 4 | 5 | public class V1RoutePort { 6 | @SerializedName("targetPort") 7 | private String targetPort = null; 8 | 9 | public String getTargetPort() { 10 | return targetPort; 11 | } 12 | 13 | public void setTargetPort(String targetPort) { 14 | this.targetPort = targetPort; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/openshift/io/V1RouteSpec.java: -------------------------------------------------------------------------------- 1 | package openshift.io; 2 | 3 | import com.google.gson.annotations.SerializedName; 4 | 5 | public class V1RouteSpec { 6 | @SerializedName("host") 7 | private String host = null; 8 | 9 | @SerializedName("port") 10 | private V1RoutePort port = null; 11 | 12 | public String getHost() { 13 | return host; 14 | } 15 | 16 | public void setHost(String host) { 17 | this.host = host; 18 | } 19 | 20 | public V1RoutePort getPort() { 21 | return port; 22 | } 23 | 24 | public void setPort(V1RoutePort port) { 25 | this.port = port; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/test/java/test/Nodes.java: -------------------------------------------------------------------------------- 1 | package test; 2 | 3 | import java.io.IOException; 4 | import java.util.concurrent.TimeUnit; 5 | 6 | import com.google.gson.reflect.TypeToken; 7 | 8 | import io.kubernetes.client.ApiClient; 9 | import io.kubernetes.client.ApiException; 10 | import io.kubernetes.client.apis.CoreV1Api; 11 | import io.kubernetes.client.models.V1NodeList; 12 | import io.kubernetes.client.util.ClientBuilder; 13 | import io.kubernetes.client.util.Watch; 14 | 15 | class Nodes { 16 | 17 | public static void main(String[] args) throws IOException, ApiException { 18 | System.out.println("monitoring nodes"); 19 | 20 | if (args.length < 2) { 21 | System.err.println("Not enough arguments provided!"); 22 | System.exit(-1); 23 | } 24 | 25 | String url = args[0]; 26 | String token = args[1]; 27 | 28 | // create config using url and token 29 | ApiClient client = ClientBuilder.kubeconfig(Main.getConfigFromToken(url, token)).build(); 30 | client.getHttpClient().setReadTimeout(0, TimeUnit.MILLISECONDS); 31 | 32 | CoreV1Api api = new CoreV1Api(); 33 | //V1NodeList nodes = 34 | Watch watch2 = 35 | Watch.createWatch( 36 | client, 37 | //apiInstance.listNamespacedCustomObjectCall(group, version, namespace, plural, pretty, null, null, null, null, Boolean.TRUE, null, null), 38 | api.listNodeCall("false" /*pretty*/, "false" /*_continue*/, null /*fieldSelector*/, null /*labelSelector*/, 0 /*limit*/, null /*resourceVersion*/, 0 /*timeoutSeconds*/, Boolean.TRUE /*watch*/, null /*progressListener*/, null /*progressRequestListener*/), 39 | new TypeToken>() {}.getType()); 40 | try { 41 | for (Watch.Response item : watch2) { 42 | System.out.printf("%s : %s%n", item.type, item.object); 43 | } 44 | } finally { 45 | watch2.close(); 46 | } 47 | } 48 | 49 | } 50 | -------------------------------------------------------------------------------- /src/test/java/test/Routes.java: -------------------------------------------------------------------------------- 1 | package test; 2 | 3 | import java.io.IOException; 4 | 5 | import com.google.gson.Gson; 6 | import com.google.gson.JsonObject; 7 | import com.google.gson.internal.LinkedTreeMap; 8 | 9 | import io.kubernetes.client.ApiClient; 10 | import io.kubernetes.client.informer.ResourceEventHandler; 11 | import io.kubernetes.client.informer.SharedIndexInformer; 12 | import io.kubernetes.client.informer.SharedInformerFactory; 13 | import io.kubernetes.client.util.CallGeneratorParams; 14 | import io.kubernetes.client.util.ClientBuilder; 15 | import kubevirt.io.V1VirtualMachine; 16 | import openshift.io.OpenshiftApi; 17 | import openshift.io.V1Route; 18 | import openshift.io.V1RouteList; 19 | import openshift.io.V1Template; 20 | import openshift.io.V1TemplateList; 21 | 22 | public class Routes { 23 | 24 | public static void main(String[] args) throws IOException { 25 | System.out.println("querying the console route"); 26 | 27 | if (args.length < 2) { 28 | System.err.println("Not enough arguments provided!"); 29 | System.exit(-1); 30 | } 31 | 32 | String url = args[0]; 33 | String token = args[1]; 34 | 35 | // create config using url and token 36 | ApiClient client = ClientBuilder.kubeconfig(Main.getConfigFromToken(url, token)).build(); 37 | 38 | OpenshiftApi api = new OpenshiftApi(client); 39 | SharedInformerFactory sharedInformerFactory = new SharedInformerFactory(); 40 | SharedIndexInformer templateInfomer = 41 | sharedInformerFactory.sharedIndexInformerFor( 42 | (CallGeneratorParams params) -> { 43 | return api.listNamespacedRouteCall( 44 | "openshift-console", 45 | null, 46 | null, 47 | null, 48 | "app=openshift-console", 49 | null, 50 | params.resourceVersion, 51 | params.timeoutSeconds, 52 | params.watch, 53 | null, 54 | null); 55 | }, 56 | V1Route.class, 57 | V1RouteList.class); 58 | 59 | templateInfomer.addEventHandler(new ResourceEventHandler() { 60 | 61 | @Override 62 | public void onAdd(V1Route obj) { 63 | System.out.println("Found console route: " + obj.getSpec().getHost()); 64 | } 65 | 66 | @Override 67 | public void onUpdate(V1Route oldObj, V1Route newObj) { 68 | // TODO Auto-generated method stub 69 | 70 | } 71 | 72 | @Override 73 | public void onDelete(V1Route obj, boolean deletedFinalStateUnknown) { 74 | // TODO Auto-generated method stub 75 | 76 | } 77 | }); 78 | 79 | sharedInformerFactory.startAllRegisteredInformers(); 80 | } 81 | } 82 | -------------------------------------------------------------------------------- /src/test/java/test/VirtualMachines.java: -------------------------------------------------------------------------------- 1 | package test; 2 | 3 | import java.io.FileNotFoundException; 4 | import java.io.FileReader; 5 | import java.io.IOException; 6 | 7 | import io.kubernetes.client.ApiClient; 8 | import io.kubernetes.client.ApiException; 9 | import io.kubernetes.client.util.ClientBuilder; 10 | import io.kubernetes.client.util.KubeConfig; 11 | import kubevirt.io.KubevirtApi; 12 | import kubevirt.io.V1VirtualMachine; 13 | import kubevirt.io.V1VirtualMachineInstance; 14 | import kubevirt.io.V1VirtualMachineInstanceList; 15 | import kubevirt.io.V1VirtualMachineList; 16 | 17 | public class VirtualMachines { 18 | 19 | public static void main(String[] args) throws ApiException, FileNotFoundException, IOException, io.kubernetes.client.ApiException { 20 | System.out.println("monitoring nodes"); 21 | 22 | if (args.length < 2) { 23 | System.err.println("Not enough arguments provided!"); 24 | System.exit(-1); 25 | } 26 | 27 | String url = args[0]; 28 | String token = args[1]; 29 | 30 | // create config using url and token 31 | ApiClient client = ClientBuilder.kubeconfig(Main.getConfigFromToken(url, token)).build(); 32 | 33 | // String kubeConfigPath = "/home/ahadas/.kube/.kubeconfig"; 34 | // // loading the out-of-cluster config, a kubeconfig from file-system 35 | // ApiClient client = 36 | // ClientBuilder.kubeconfig(KubeConfig.loadKubeConfig(new FileReader(kubeConfigPath))).build(); 37 | 38 | // System.out.print 39 | // OAuth o = (OAuth) c.getAuthentication("oauth2"); 40 | // String b = "eyJhbGciOiJSUzI1NiIsImtpZCI6IiJ9.eyJpc3MiOiJrdWJlcm5ldGVzL3NlcnZpY2VhY2NvdW50Iiwia3ViZXJuZXRlcy5pby9zZXJ2aWNlYWNjb3VudC9uYW1lc3BhY2UiOiJkZWZhdWx0Iiwia3ViZXJuZXRlcy5pby9zZXJ2aWNlYWNjb3VudC9zZWNyZXQubmFtZSI6ImRlZmF1bHQtdG9rZW4tdGdzc2oiLCJrdWJlcm5ldGVzLmlvL3NlcnZpY2VhY2NvdW50L3NlcnZpY2UtYWNjb3VudC5uYW1lIjoiZGVmYXVsdCIsImt1YmVybmV0ZXMuaW8vc2VydmljZWFjY291bnQvc2VydmljZS1hY2NvdW50LnVpZCI6IjM1ZTc5MWUxLTAyZWMtMTFlYS05YzUyLTUyNTUwMGQxNTUwMSIsInN1YiI6InN5c3RlbTpzZXJ2aWNlYWNjb3VudDpkZWZhdWx0OmRlZmF1bHQifQ.VQq39XUzZn5d5l24yfNLpO4HjOQqG24pdrlVx-EyWWon49iP4gMutg8yx-UjjFE5si9dMZKxzE4bGP9q3o99Rt5s85_txZuIAU9Z7loVkCmSJPZx_12B2QK9OmizfEAMvomcT295oraL90f6RrRRtYNZ4DfHuYCwR6TySACFK56yN7-pGn1QxCbVuGibF0LHLuMhwRMX6evDxVfPzZqAMC6hHeCHsWqj8YS1eGkZb0HYqRPtkdLfgwEK3ZtBglD5xzORagFUQaLYJIlAei8WLSAkJmvrU8j2awH0P4RvW7VR7ytTTmzHlTLTURft1BHLpm_vT19PyVRsZfvwjl0Wow"; 41 | // o.setAccessToken(b); 42 | // c.setBasePath("https://127.0.0.1:32768"); 43 | //// c.setVerifyingSsl(false); 44 | // CoreV1Api aa = new CoreV1Api(c); 45 | // Object bcd = aa.listNamespace(null, null, null, null, null, null, null, null); 46 | // System.out.println(bcd); 47 | 48 | // loading the out-of-cluster config, a kubeconfig from file-system 49 | // io.kubernetes.client.ApiClient kubernetes = 50 | // ClientBuilder.kubeconfig(KubeConfig.loadKubeConfig(new FileReader(kubeConfigPath))).build(); 51 | // OAuth oo = new OAuth(); 52 | // oo.setAccessToken(a); 53 | client.setDebugging(true); 54 | KubevirtApi api = new KubevirtApi(client); 55 | 56 | try { 57 | api.checkHealth(); 58 | System.out.println("health ok"); 59 | } catch (ApiException e) { 60 | System.out.println("health not ok"); 61 | } 62 | 63 | V1VirtualMachineList l = api.listVirtualMachineForAllNamespaces(null, null, null, null, null, null, null, null); 64 | System.out.println("VMs: " + l); 65 | V1VirtualMachine v = l.getItems().get(0); 66 | // V1VirtualMachine v1 = new V1VirtualMachine(); 67 | v.getMetadata().setResourceVersion(null); 68 | v.getMetadata().setName("arik"); 69 | // api.createNamespacedVirtualMachine(v, "default"); 70 | 71 | V1VirtualMachineInstanceList l2 = api.listVirtualMachineInstanceForAllNamespaces(null, null, null, null, null, null, null, null); 72 | System.out.println("VMIs: " + l2); 73 | V1VirtualMachineInstance v3 = l2.getItems().get(0); 74 | } 75 | 76 | } 77 | -------------------------------------------------------------------------------- /swagger-codegen-cli-2.4.9.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/oVirt/java-client-kubevirt/2cd69335f3167b6c8a89fc412f78aa97e366facb/swagger-codegen-cli-2.4.9.jar --------------------------------------------------------------------------------