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

org.ovirt.engine.sdk4.internal.containers.QuotaContainer Maven / Gradle / Ivy

There is a newer version: 4.5.1
Show newest version
/*
Copyright (c) 2015 Red Hat, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

package org.ovirt.engine.sdk4.internal.containers;

import java.math.BigInteger;
import java.util.List;
import org.ovirt.engine.sdk4.types.DataCenter;
import org.ovirt.engine.sdk4.types.Disk;
import org.ovirt.engine.sdk4.types.Permission;
import org.ovirt.engine.sdk4.types.Quota;
import org.ovirt.engine.sdk4.types.QuotaClusterLimit;
import org.ovirt.engine.sdk4.types.QuotaStorageLimit;
import org.ovirt.engine.sdk4.types.User;
import org.ovirt.engine.sdk4.types.Vm;

public class QuotaContainer extends IdentifiedContainer implements Quota {
    private BigInteger clusterHardLimitPct;
    private BigInteger clusterSoftLimitPct;
    private DataCenter dataCenter;
    private List disks;
    private BigInteger storageHardLimitPct;
    private BigInteger storageSoftLimitPct;
    private List users;
    private List vms;
    private List permissions;
    private List quotaClusterLimits;
    private List quotaStorageLimits;
    
    public BigInteger clusterHardLimitPct() {
        return clusterHardLimitPct;
    }
    
    public void clusterHardLimitPct(BigInteger newClusterHardLimitPct) {
        clusterHardLimitPct = newClusterHardLimitPct;
    }
    
    public boolean clusterHardLimitPctPresent() {
        return clusterHardLimitPct != null;
    }
    
    public BigInteger clusterSoftLimitPct() {
        return clusterSoftLimitPct;
    }
    
    public void clusterSoftLimitPct(BigInteger newClusterSoftLimitPct) {
        clusterSoftLimitPct = newClusterSoftLimitPct;
    }
    
    public boolean clusterSoftLimitPctPresent() {
        return clusterSoftLimitPct != null;
    }
    
    public DataCenter dataCenter() {
        return dataCenter;
    }
    
    public void dataCenter(DataCenter newDataCenter) {
        dataCenter = newDataCenter;
    }
    
    public boolean dataCenterPresent() {
        return dataCenter != null;
    }
    
    public List disks() {
        return makeUnmodifiableList(disks);
    }
    
    public void disks(List newDisks) {
        disks = makeArrayList(newDisks);
    }
    
    public boolean disksPresent() {
        return disks != null && !disks.isEmpty();
    }
    
    public BigInteger storageHardLimitPct() {
        return storageHardLimitPct;
    }
    
    public void storageHardLimitPct(BigInteger newStorageHardLimitPct) {
        storageHardLimitPct = newStorageHardLimitPct;
    }
    
    public boolean storageHardLimitPctPresent() {
        return storageHardLimitPct != null;
    }
    
    public BigInteger storageSoftLimitPct() {
        return storageSoftLimitPct;
    }
    
    public void storageSoftLimitPct(BigInteger newStorageSoftLimitPct) {
        storageSoftLimitPct = newStorageSoftLimitPct;
    }
    
    public boolean storageSoftLimitPctPresent() {
        return storageSoftLimitPct != null;
    }
    
    public List users() {
        return makeUnmodifiableList(users);
    }
    
    public void users(List newUsers) {
        users = makeArrayList(newUsers);
    }
    
    public boolean usersPresent() {
        return users != null && !users.isEmpty();
    }
    
    public List vms() {
        return makeUnmodifiableList(vms);
    }
    
    public void vms(List newVms) {
        vms = makeArrayList(newVms);
    }
    
    public boolean vmsPresent() {
        return vms != null && !vms.isEmpty();
    }
    
    public List permissions() {
        return makeUnmodifiableList(permissions);
    }
    
    public void permissions(List newPermissions) {
        permissions = makeArrayList(newPermissions);
    }
    
    public boolean permissionsPresent() {
        return permissions != null && !permissions.isEmpty();
    }
    
    public List quotaClusterLimits() {
        return makeUnmodifiableList(quotaClusterLimits);
    }
    
    public void quotaClusterLimits(List newQuotaClusterLimits) {
        quotaClusterLimits = makeArrayList(newQuotaClusterLimits);
    }
    
    public boolean quotaClusterLimitsPresent() {
        return quotaClusterLimits != null && !quotaClusterLimits.isEmpty();
    }
    
    public List quotaStorageLimits() {
        return makeUnmodifiableList(quotaStorageLimits);
    }
    
    public void quotaStorageLimits(List newQuotaStorageLimits) {
        quotaStorageLimits = makeArrayList(newQuotaStorageLimits);
    }
    
    public boolean quotaStorageLimitsPresent() {
        return quotaStorageLimits != null && !quotaStorageLimits.isEmpty();
    }
    
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy