public class ConvertInternalCacheSettings
extends java.lang.Object
implements com.exalead.util.Checkable, java.io.Serializable
Modifier and Type | Field and Description |
---|---|
static long |
DEFAULT_MAX_AGE_S |
static int |
DEFAULT_MAX_SIZE_M_B |
static int |
DEFAULT_MAX_SIZE_PER_FILE_K_B |
static long |
DEFAULT_MIN_AGE_S |
long |
maxAgeS |
int |
maxSizeMB |
int |
maxSizePerFileKB |
long |
minAgeS |
Constructor and Description |
---|
ConvertInternalCacheSettings() |
ConvertInternalCacheSettings(ConvertInternalCacheSettings o)
Copy constructor
|
Modifier and Type | Method and Description |
---|---|
void |
check(boolean deep,
java.lang.String errorContext)
Checks this ConvertInternalCacheSettings.
|
static ConvertInternalCacheSettings |
fromString(java.lang.String s)
String representation of this ConvertInternalCacheSettings.
|
long |
getMaxAgeS()
Maximum age (in seconds) for an item in the cache.
The default is -1 which means no limit. |
int |
getMaxSizeMB()
Maximum size (in megabytes) for the cache.
The default is -1 which means no limit. |
int |
getMaxSizePerFileKB()
Maximum size (in kilobytes) for an item to be cached.
The default is -1 which means no limit. |
long |
getMinAgeS()
Minimum age (in seconds) for an item in the cache.
This is useful for big files that we don't want to frequently update in the cache, for performance reasons. The default is -1 which means no limit. |
ConvertInternalCacheSettings |
makeCopy()
Creates and returns a deep copy of this ConvertInternalCacheSettings.
|
static ConvertInternalCacheSettings |
readFrom(java.io.InputStream is)
Read this ConvertInternalCacheSettings from an XML fragment.
|
void |
setMaxAgeS(long maxAgeS)
Maximum age (in seconds) for an item in the cache.
The default is -1 which means no limit. |
void |
setMaxSizeMB(int maxSizeMB)
Maximum size (in megabytes) for the cache.
The default is -1 which means no limit. |
void |
setMaxSizePerFileKB(int maxSizePerFileKB)
Maximum size (in kilobytes) for an item to be cached.
The default is -1 which means no limit. |
void |
setMinAgeS(long minAgeS)
Minimum age (in seconds) for an item in the cache.
This is useful for big files that we don't want to frequently update in the cache, for performance reasons. The default is -1 which means no limit. |
java.lang.String |
toString()
String representation of this ConvertInternalCacheSettings.
|
ConvertInternalCacheSettings |
withMaxAgeS(long maxAgeS) |
ConvertInternalCacheSettings |
withMaxAgeS(java.lang.Long maxAgeS) |
ConvertInternalCacheSettings |
withMaxSizeMB(int maxSizeMB) |
ConvertInternalCacheSettings |
withMaxSizeMB(java.lang.Integer maxSizeMB) |
ConvertInternalCacheSettings |
withMaxSizePerFileKB(int maxSizePerFileKB) |
ConvertInternalCacheSettings |
withMaxSizePerFileKB(java.lang.Integer maxSizePerFileKB) |
ConvertInternalCacheSettings |
withMinAgeS(long minAgeS) |
ConvertInternalCacheSettings |
withMinAgeS(java.lang.Long minAgeS) |
void |
writeTo(java.io.OutputStream os)
Write this ConvertInternalCacheSettings as an XML fragment
|
public long minAgeS
public static final long DEFAULT_MIN_AGE_S
public long maxAgeS
public static final long DEFAULT_MAX_AGE_S
public int maxSizeMB
public static final int DEFAULT_MAX_SIZE_M_B
public int maxSizePerFileKB
public static final int DEFAULT_MAX_SIZE_PER_FILE_K_B
public ConvertInternalCacheSettings()
public ConvertInternalCacheSettings(ConvertInternalCacheSettings o)
public void setMinAgeS(long minAgeS)
public long getMinAgeS()
public ConvertInternalCacheSettings withMinAgeS(long minAgeS)
public ConvertInternalCacheSettings withMinAgeS(java.lang.Long minAgeS)
public void setMaxAgeS(long maxAgeS)
public long getMaxAgeS()
public ConvertInternalCacheSettings withMaxAgeS(long maxAgeS)
public ConvertInternalCacheSettings withMaxAgeS(java.lang.Long maxAgeS)
public void setMaxSizeMB(int maxSizeMB)
public int getMaxSizeMB()
public ConvertInternalCacheSettings withMaxSizeMB(int maxSizeMB)
public ConvertInternalCacheSettings withMaxSizeMB(java.lang.Integer maxSizeMB)
public void setMaxSizePerFileKB(int maxSizePerFileKB)
public int getMaxSizePerFileKB()
public ConvertInternalCacheSettings withMaxSizePerFileKB(int maxSizePerFileKB)
public ConvertInternalCacheSettings withMaxSizePerFileKB(java.lang.Integer maxSizePerFileKB)
public ConvertInternalCacheSettings makeCopy()
public static ConvertInternalCacheSettings readFrom(java.io.InputStream is) throws javax.xml.bind.JAXBException
javax.xml.bind.JAXBException
public void writeTo(java.io.OutputStream os) throws javax.xml.bind.JAXBException, java.io.IOException
javax.xml.bind.JAXBException
java.io.IOException
public static ConvertInternalCacheSettings fromString(java.lang.String s) throws javax.xml.bind.JAXBException, java.io.UnsupportedEncodingException
javax.xml.bind.JAXBException
java.io.UnsupportedEncodingException
public java.lang.String toString()
toString
in class java.lang.Object
public void check(boolean deep, java.lang.String errorContext) throws com.exalead.util.TypedException
check
in interface com.exalead.util.Checkable
com.exalead.util.TypedException
Copyright © 2021 Dassault Systèmes, All Rights Reserved.