SIL.FieldWorks.CacheLight.RealDataCache.AddToLongCache C# (CSharp) Method

AddToLongCache() private method

private AddToLongCache ( int obj, int tag, long val, CellarPropertyType flidType ) : void
obj int
tag int
val long
flidType CellarPropertyType
return void
		private void AddToLongCache(int obj, int tag, long val, CellarPropertyType flidType)
		{
			CheckBasics(obj);

			// Make sure the hvo has the given tag.
			CheckHvoTagMatch(obj, tag);
			// Make sure a long is legal for the given tag.
			CellarPropertyType tagType = (CellarPropertyType)MetaDataCache.GetFieldType(tag);
			if (tagType != flidType)
				throw new ArgumentException(String.Format("Can only put long integers in the tag/flid '{0}'.", tag));
			m_longCache[new HvoFlidKey(obj, tag)] = val;
		}