Пример #1
0
		internal void AddNativeState(State newState)
		{
			m_nativeStates.Add(newState.StateId, newState);
			CacheAdd(newState.StateId, newState);
		}
Пример #2
0
		private void CacheAdd(TStateId id, State ref_)
		{
			var newState = ref_;
			StateCacheEntry entry;
			if (!m_stateCache.TryGetValue(newState.StateId, out entry))
			{
				entry = new StateCacheEntry();
				m_stateCache.Add(newState.StateId, entry);
			}
			entry.ref_ = newState;
			entry.lastTouch = DateTime.Now;
			++entry.refCount;
		}
Пример #3
0
		public void TryFire(State state)
		{
			if (m_condition(state))
				m_response(state);
		}
Пример #4
0
		public static void OnBankrupt(State acc)
		{

		}
Пример #5
0
		public bool RegisterObject(TStateId sid, string objType, State ptr)
		{
			return m_naming.RegisterObject(sid.ToString(), objType, ptr);
		}
Пример #6
0
		public bool RegisterObject(string objName, string objType, State ptr)
		{
			m_objects.Add(objName, new Entry() { type = objType, ptr = ptr });
			return true;
		}