Package system.runtime.caching
Class ObjectCache
- java.lang.Object
-
- org.mases.jcobridge.netreflection.NetObject
-
- org.mases.jcobridge.netreflection.NetObjectEnumerable
-
- system.runtime.caching.ObjectCache
-
- All Implemented Interfaces:
java.lang.Iterable<NetObject>
,IEnumerable
,IJCOBridgeReflected
- Direct Known Subclasses:
MemoryCache
public class ObjectCache extends NetObjectEnumerable
The base .NET class managing System.Runtime.Caching.ObjectCache, System.Runtime.Caching, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a..NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.Runtime.Caching.ObjectCache
Powered by JCOBridge: more info at https://www.jcobridge.com
- Author:
- MASES s.r.l https://masesgroup.com
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
assemblyFullName
Fully assembly qualified name: System.Runtime.Caching, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3astatic java.lang.String
assemblyShortName
Assembly name: System.Runtime.Cachingstatic java.lang.String
className
Qualified class name: System.Runtime.Caching.ObjectCachestatic JCType
classType
The type managed from JCOBridge.-
Fields inherited from class org.mases.jcobridge.netreflection.NetObjectEnumerable
Null
-
-
Constructor Summary
Constructors Constructor Description ObjectCache()
ObjectCache(java.lang.Object instance)
Internal constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
Add(java.lang.String key, NetObject value, DateTimeOffset absoluteExpiration, java.lang.String regionName)
boolean
Add(java.lang.String key, NetObject value, CacheItemPolicy policy, java.lang.String regionName)
boolean
Add(CacheItem item, CacheItemPolicy policy)
NetObject
AddOrGetExisting(java.lang.String key, NetObject value, DateTimeOffset absoluteExpiration, java.lang.String regionName)
NetObject
AddOrGetExisting(java.lang.String key, NetObject value, CacheItemPolicy policy, java.lang.String regionName)
CacheItem
AddOrGetExisting(CacheItem value, CacheItemPolicy policy)
static ObjectCache
cast(IJCOBridgeReflected from)
Try to cast theIJCOBridgeReflected
instance intoObjectCache
, a cast assert is made to check if types are compatible.boolean
Contains(java.lang.String key, java.lang.String regionName)
NetObject
Get(java.lang.String key, java.lang.String regionName)
CacheItem
GetCacheItem(java.lang.String key, java.lang.String regionName)
long
GetCount(java.lang.String regionName)
DefaultCacheCapabilities
getDefaultCacheCapabilities()
static IServiceProvider
getHost()
java.lang.String
getJCOAssemblyName()
Returns the reflected Assembly namejava.lang.String
getJCOClassName()
Returns the reflected Class namejava.lang.Object
getJCOInstance()
Returns the instantiated classjava.lang.String
getJCOObjectName()
Returns the reflected Class name used to build the objectJCType
getJCOType()
Returns the instantiated class Typejava.lang.String
getName()
NetObject
Remove(java.lang.String key, java.lang.String regionName)
void
Set(java.lang.String key, NetObject value, DateTimeOffset absoluteExpiration, java.lang.String regionName)
void
Set(java.lang.String key, NetObject value, CacheItemPolicy policy, java.lang.String regionName)
void
Set(CacheItem item, CacheItemPolicy policy)
static void
setHost(IServiceProvider Host)
void
setJCOInstance(JCObject instance)
-
Methods inherited from class org.mases.jcobridge.netreflection.NetObjectEnumerable
GetEnumerator, iterator
-
-
-
-
Field Detail
-
assemblyFullName
public static final java.lang.String assemblyFullName
Fully assembly qualified name: System.Runtime.Caching, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a- See Also:
- Constant Field Values
-
assemblyShortName
public static final java.lang.String assemblyShortName
Assembly name: System.Runtime.Caching- See Also:
- Constant Field Values
-
className
public static final java.lang.String className
Qualified class name: System.Runtime.Caching.ObjectCache- See Also:
- Constant Field Values
-
-
Method Detail
-
getJCOAssemblyName
public java.lang.String getJCOAssemblyName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Assembly name- Specified by:
getJCOAssemblyName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOAssemblyName
in classNetObjectEnumerable
- Returns:
- A
String
representing the Fullname of reflected Assembly
-
getJCOClassName
public java.lang.String getJCOClassName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name- Specified by:
getJCOClassName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOClassName
in classNetObjectEnumerable
- Returns:
- A
String
representing the Fullname of reflected Class
-
getJCOObjectName
public java.lang.String getJCOObjectName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name used to build the object- Specified by:
getJCOObjectName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOObjectName
in classNetObjectEnumerable
- Returns:
- A
String
representing the name used to allocated the object in CLR context
-
getJCOInstance
public java.lang.Object getJCOInstance()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class- Specified by:
getJCOInstance
in interfaceIJCOBridgeReflected
- Overrides:
getJCOInstance
in classNetObjectEnumerable
- Returns:
- An
Object
representing the CLR instance of the instantiated Class
-
setJCOInstance
public void setJCOInstance(JCObject instance)
- Overrides:
setJCOInstance
in classNetObjectEnumerable
-
getJCOType
public JCType getJCOType()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class Type- Specified by:
getJCOType
in interfaceIJCOBridgeReflected
- Overrides:
getJCOType
in classNetObjectEnumerable
- Returns:
- A
JCType
representing the CLR Type of the instantiated Class
-
cast
public static ObjectCache cast(IJCOBridgeReflected from) throws java.lang.Throwable
Try to cast theIJCOBridgeReflected
instance intoObjectCache
, a cast assert is made to check if types are compatible.- Parameters:
from
-IJCOBridgeReflected
instance to be casted- Returns:
ObjectCache
instance- Throws:
java.lang.Throwable
- in case of error during cast operation
-
Add
public boolean Add(CacheItem item, CacheItemPolicy policy) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Add
public boolean Add(java.lang.String key, NetObject value, DateTimeOffset absoluteExpiration, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Add
public boolean Add(java.lang.String key, NetObject value, CacheItemPolicy policy, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Contains
public boolean Contains(java.lang.String key, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
GetCount
public long GetCount(java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
AddOrGetExisting
public NetObject AddOrGetExisting(java.lang.String key, NetObject value, DateTimeOffset absoluteExpiration, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
AddOrGetExisting
public NetObject AddOrGetExisting(java.lang.String key, NetObject value, CacheItemPolicy policy, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Get
public NetObject Get(java.lang.String key, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Remove
public NetObject Remove(java.lang.String key, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
AddOrGetExisting
public CacheItem AddOrGetExisting(CacheItem value, CacheItemPolicy policy) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
GetCacheItem
public CacheItem GetCacheItem(java.lang.String key, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Set
public void Set(CacheItem item, CacheItemPolicy policy) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Set
public void Set(java.lang.String key, NetObject value, DateTimeOffset absoluteExpiration, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
Set
public void Set(java.lang.String key, NetObject value, CacheItemPolicy policy, java.lang.String regionName) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getHost
public static IServiceProvider getHost() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
setHost
public static void setHost(IServiceProvider Host) throws java.lang.Throwable, ArgumentNullException, ArgumentException, TypeLoadException, InvalidOperationException, MissingMethodException, TargetInvocationException, NotSupportedException, NotImplementedException, ArgumentOutOfRangeException, IndexOutOfRangeException, CultureNotFoundException, OutOfMemoryException, MissingManifestResourceException, ObjectDisposedException
- Throws:
java.lang.Throwable
ArgumentNullException
ArgumentException
TypeLoadException
InvalidOperationException
MissingMethodException
TargetInvocationException
NotSupportedException
NotImplementedException
ArgumentOutOfRangeException
IndexOutOfRangeException
CultureNotFoundException
OutOfMemoryException
MissingManifestResourceException
ObjectDisposedException
-
getDefaultCacheCapabilities
public DefaultCacheCapabilities getDefaultCacheCapabilities() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
getName
public java.lang.String getName() throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
-