Cisco Systems, Inc.

com.pcube.apps.console.quota.data
Class QuotaProfileDataGy

java.lang.Object
  extended by com.pcube.apps.console.quota.data.QuotaProfileData
      extended by com.pcube.apps.console.quota.data.QuotaProfileDataGy
All Implemented Interfaces:
Formattable

public class QuotaProfileDataGy
extends QuotaProfileData

Quota Profile for Gy. Holds all attachments (which service goes to which bucket). Also contains all buckets special configuration and per Package Gy Special parameters such as Tarrif Time.

Author:
rbaryana

Field Summary
 
Fields inherited from class com.pcube.apps.console.quota.data.QuotaProfileData
DEFAULT_PROFILE_NAME
 
Constructor Summary
QuotaProfileDataGy(QuotaServiceAttachmentList attachemntList, Policy policy)
           
 
Method Summary
 void attachBucket(Service service, int bucket)
          attach gy bucket to service.
 void attachBucket(Service service, int bucketId, int serviceFrameNum)
          attach gy bucket to service.
 void copyData(QuotaProfileData temp)
          copy the all data from temp profile.
 QuotaProfileData duplicate()
           
 void fromStream(java.io.BufferedReader in, Formatter f)
          Read profile cfg from PQB.
 QuotaVolumeAccountingUnitsData getAccountingUnitsData()
           
 long getTariffChnageTime(int idx)
           
 QuotaBucketData getUnlimitedBucket()
           
 void setTariffChnageTime(int idx, long tariffChnageTime)
          Configure tariff time change time.
 void toStream(java.io.PrintStream out, Formatter f)
          Write profile to pqb.
 
Methods inherited from class com.pcube.apps.console.quota.data.QuotaProfileData
getAllBuckets, getAllUsedBucketsMask, getAttachmentList, getBucketById, getBucketTypeOptimization, getDownloadBucket, getDownloadBucket, getMyId, getMyName, getNumberOfBuckets, getQuotaServiceAttachment, getSessionBucket, getSessionBucket, getType, getUploadBucket, getUploadBucket, getVolumeAccountingUnits, isDefault, isExternal, isReadOnly, setMyName, setQuotaServiceAttachmentList, setVolumeAccountingUnits
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QuotaProfileDataGy

public QuotaProfileDataGy(QuotaServiceAttachmentList attachemntList,
                          Policy policy)
Method Detail

copyData

public void copyData(QuotaProfileData temp)
Description copied from class: QuotaProfileData
copy the all data from temp profile.

Specified by:
copyData in class QuotaProfileData

duplicate

public QuotaProfileData duplicate()
Specified by:
duplicate in class QuotaProfileData
Returns:
a copy of the profile

getUnlimitedBucket

public QuotaBucketData getUnlimitedBucket()
Specified by:
getUnlimitedBucket in class QuotaProfileData
Returns:
the unlimited quota bucket (default)

fromStream

public void fromStream(java.io.BufferedReader in,
                       Formatter f)
                throws ImportExportException
Read profile cfg from PQB. (non-Javadoc)

Specified by:
fromStream in interface Formattable
Overrides:
fromStream in class QuotaProfileData
Throws:
ImportExportException
See Also:
Formattable.fromStream(java.io.BufferedReader, com.pcube.apps.engage.common.Formatter)

toStream

public void toStream(java.io.PrintStream out,
                     Formatter f)
Write profile to pqb. (non-Javadoc)

Specified by:
toStream in interface Formattable
Overrides:
toStream in class QuotaProfileData
See Also:
Formattable.toStream(java.io.PrintStream, com.pcube.apps.engage.common.Formatter)

getTariffChnageTime

public long getTariffChnageTime(int idx)
Parameters:
idx - (0 is first index)
Returns:

setTariffChnageTime

public void setTariffChnageTime(int idx,
                                long tariffChnageTime)
Configure tariff time change time.

Parameters:
tariffChnageTime - - time in seconds.

getAccountingUnitsData

public QuotaVolumeAccountingUnitsData getAccountingUnitsData()
Specified by:
getAccountingUnitsData in class QuotaProfileData
Returns:
the volume acconting units as wrapped object.

attachBucket

public void attachBucket(Service service,
                         int bucket)
                  throws QuotaDataException
attach gy bucket to service.

Parameters:
service -
bucket -
Throws:
QuotaDataException

attachBucket

public void attachBucket(Service service,
                         int bucketId,
                         int serviceFrameNum)
                  throws QuotaDataException
attach gy bucket to service.

Parameters:
service -
bucketId -
serviceFrameNum -
Throws:
QuotaDataException

Cisco Systems, Inc.

Copyright © 2013 Cisco Systems, Inc. Confidential.