Show / Hide Table of Contents

Interface IObjectStore

Outlines interface for object store

Inherited Members
IApplicationComponent.ComponentSID
IApplicationComponent.ComponentDirector
IApplicationComponent.ComponentCommonName
System.IDisposable.Dispose()
ILocalizedTimeProvider.TimeLocation
ILocalizedTimeProvider.LocalizedTime
ILocalizedTimeProvider.UniversalTimeToLocalizedTime(DateTime)
ILocalizedTimeProvider.LocalizedTimeToUniversalTime(DateTime)
Namespace: NFX.ApplicationModel.Volatile
Assembly: NFX.dll
Syntax
public interface IObjectStore : IApplicationComponent, IDisposable, ILocalizedTimeProvider

Properties

ObjectLifeSpanMS

Specifies how long objects live without being touched before becoming evicted from the list

Declaration
int ObjectLifeSpanMS { get; }
Property Value
Type Description
System.Int32

Methods

CheckIn(Guid, Int32)

Puts an object into store identified by the "key"

Declaration
bool CheckIn(Guid key, int msTimeout = 0)
Parameters
Type Name Description
System.Guid key
System.Int32 msTimeout
Returns
Type Description
System.Boolean

CheckIn(Guid, Object, Int32)

Puts an object reference "value" into store identified by the "key"

Declaration
void CheckIn(Guid key, object value, int msTimeout = 0)
Parameters
Type Name Description
System.Guid key
System.Object value
System.Int32 msTimeout

CheckInUnderNewKey(Guid, Guid, Object, Int32)

Puts an object reference "value" into store identified by the "oldKey" under the "newKey". If oldKey was not checked in, then checks-in under new key as normally would

Declaration
void CheckInUnderNewKey(Guid oldKey, Guid newKey, object value, int msTimeout = 0)
Parameters
Type Name Description
System.Guid oldKey
System.Guid newKey
System.Object value
System.Int32 msTimeout

CheckOut(Guid)

Retrieves an object reference from the store identified by the "key" or returns null if such object does not exist. Object is not going to be persisted until it is checked back in the store.

Declaration
object CheckOut(Guid key)
Parameters
Type Name Description
System.Guid key
Returns
Type Description
System.Object

Delete(Guid)

Deletes object identified by key. Returns true when object was found and marked for deletion

Declaration
bool Delete(Guid key)
Parameters
Type Name Description
System.Guid key
Returns
Type Description
System.Boolean

Fetch(Guid, Boolean)

Retrieves an object reference from the store identified by the "key" or returns null if such object does not exist. Object is not going to be persisted as this method provides logical read-only access. If touch=true then object timestamp is updated

Declaration
object Fetch(Guid key, bool touch = false)
Parameters
Type Name Description
System.Guid key
System.Boolean touch
Returns
Type Description
System.Object

UndoCheckout(Guid)

Reverts object state to Normal after the call to Checkout. This way the changes (if any) are not going to be persisted. Returns true if object was found and checkout canceled. Keep in mind: this method CAN NOT revert inner object state to its original state if it was changed, it only unmarks object as changed. This method is reentrant just like the Checkout is

Declaration
bool UndoCheckout(Guid key)
Parameters
Type Name Description
System.Guid key
Returns
Type Description
System.Boolean

Extension Methods

MiscUtils.NonNull<T>(T, Func<Exception>, String)
ObjectValueConversion.AsString(Object, String, ConvertErrorHandling)
ObjectValueConversion.AsNonNullOrEmptyString(Object)
ObjectValueConversion.AsLaconicConfig(Object, ConfigSectionNode, String, ConvertErrorHandling)
ObjectValueConversion.AsJSONConfig(Object, ConfigSectionNode, String, ConvertErrorHandling)
ObjectValueConversion.AsXMLConfig(Object, ConfigSectionNode, ConvertErrorHandling)
ObjectValueConversion.AsChar(Object, Char, ConvertErrorHandling)
ObjectValueConversion.AsNullableChar(Object, Nullable<Char>, ConvertErrorHandling)
ObjectValueConversion.AsByte(Object, Byte, ConvertErrorHandling)
ObjectValueConversion.AsNullableByte(Object, Nullable<Byte>, ConvertErrorHandling)
ObjectValueConversion.AsSByte(Object, SByte, ConvertErrorHandling)
ObjectValueConversion.AsNullableSByte(Object, Nullable<SByte>, ConvertErrorHandling)
ObjectValueConversion.AsShort(Object, Int16, ConvertErrorHandling)
ObjectValueConversion.AsNullableShort(Object, Nullable<Int16>, ConvertErrorHandling)
ObjectValueConversion.AsUShort(Object, UInt16, ConvertErrorHandling)
ObjectValueConversion.AsNullableUShort(Object, Nullable<UInt16>, ConvertErrorHandling)
ObjectValueConversion.AsInt(Object, Int32, ConvertErrorHandling)
ObjectValueConversion.AsNullableInt(Object, Nullable<Int32>, ConvertErrorHandling)
ObjectValueConversion.AsUInt(Object, UInt32, ConvertErrorHandling)
ObjectValueConversion.AsNullableUInt(Object, Nullable<UInt32>, ConvertErrorHandling)
ObjectValueConversion.AsLong(Object, Int64, ConvertErrorHandling)
ObjectValueConversion.AsNullableLong(Object, Nullable<Int64>, ConvertErrorHandling)
ObjectValueConversion.AsULong(Object, UInt64, ConvertErrorHandling)
ObjectValueConversion.AsNullableULong(Object, Nullable<UInt64>, ConvertErrorHandling)
ObjectValueConversion.AsDouble(Object, Double, ConvertErrorHandling)
ObjectValueConversion.AsNullableDouble(Object, Nullable<Double>, ConvertErrorHandling)
ObjectValueConversion.AsFloat(Object, Single, ConvertErrorHandling)
ObjectValueConversion.AsNullableFloat(Object, Nullable<Single>, ConvertErrorHandling)
ObjectValueConversion.AsDecimal(Object, Decimal, ConvertErrorHandling)
ObjectValueConversion.AsNullableDecimal(Object, Nullable<Decimal>, ConvertErrorHandling)
ObjectValueConversion.AsBool(Object, Boolean, ConvertErrorHandling)
ObjectValueConversion.AsNullableBool(Object, Nullable<Boolean>, ConvertErrorHandling)
ObjectValueConversion.AsGUID(Object, Guid, ConvertErrorHandling)
ObjectValueConversion.AsNullableGUID(Object, Nullable<Guid>, ConvertErrorHandling)
ObjectValueConversion.AsDateTime(Object)
ObjectValueConversion.AsDateTime(Object, DateTime, ConvertErrorHandling)
ObjectValueConversion.AsNullableDateTime(Object, Nullable<DateTime>, ConvertErrorHandling)
ObjectValueConversion.AsGDID(Object)
ObjectValueConversion.AsGDID(Object, GDID, ConvertErrorHandling)
ObjectValueConversion.AsNullableGDID(Object, Nullable<GDID>, ConvertErrorHandling)
ObjectValueConversion.AsGDIDSymbol(Object)
ObjectValueConversion.AsGDIDSymbol(Object, GDIDSymbol, ConvertErrorHandling)
ObjectValueConversion.AsNullableGDIDSymbol(Object, Nullable<GDIDSymbol>, ConvertErrorHandling)
ObjectValueConversion.AsTimeSpan(Object)
ObjectValueConversion.AsTimeSpan(Object, TimeSpan, ConvertErrorHandling)
ObjectValueConversion.AsNullableTimeSpan(Object, Nullable<TimeSpan>, ConvertErrorHandling)
ObjectValueConversion.AsEnum<TEnum>(Object, TEnum, ConvertErrorHandling)
ObjectValueConversion.AsNullableEnum<TEnum>(Object, Nullable<TEnum>, ConvertErrorHandling)
ObjectValueConversion.AsUri(Object, Uri, ConvertErrorHandling)
JSONExtensions.ToJSON(Object, JSONWritingOptions)
JSONExtensions.ToJSON(Object, TextWriter, JSONWritingOptions)
JSONExtensions.ToJSON(Object, Stream, JSONWritingOptions, Encoding)
ErlObject.ToErlObject(Object)
ErlObject.ToErlObject(Object, ErlTypeOrder, Boolean)
Back to top Copyright © 2006-2018 Agnicore Inc
Generated by DocFX