//public abstract int FindRow( int nRow ); public abstract int FindColValue(int nCol, NFIDataList var, ref NFIDataList varResult);
public abstract int FindInt(int nCol, Int64 value, ref NFIDataList varResult);
public abstract int AddRow(int nRow, NFIDataList var);
// set data public abstract int SetValue(int nRow, NFIDataList var);
public abstract void DoEvent(NFGUID self, int nEventID, NFIDataList valueList);
public abstract void DoEvent(NFIDataList valueList);
public override void RegisterCallback(NFGUID self, int nEventID, NFIEvent.EventHandler handler, NFIDataList valueList) { Dictionary <int, NFIEvent> xData = mhtEvent[self]; if (!mhtEvent.ContainsKey(self) || null == xData) { xData = new Dictionary <int, NFIEvent>(); xData.Add(nEventID, new NFCEvent(self, nEventID, valueList)); mhtEvent.Add(self, xData); return; } if (!xData.ContainsKey(nEventID)) { xData.Add(nEventID, new NFCEvent(self, nEventID, valueList)); return; } NFIEvent identEvent = (NFIEvent)mhtEvent[self][nEventID]; identEvent.RegisterCallback(handler); }
public abstract int FindObject(int nCol, NFGUID value, ref NFIDataList varResult);
public abstract NFIProperty AddProperty(string strPropertyName, NFIDataList varData);
public abstract bool SetProperty(string strPropertyName, NFIDataList varData);
public abstract int FindRecordRow(NFGUID self, string strRecordName, int nCol, NFVector3 nValue, ref NFIDataList xDatalist);
public abstract NFIObject CreateObject(NFGUID self, int nContainerID, int nGroupID, string strClassName, string strConfigIndex, NFIDataList arg);
public NFCEvent(NFGUID self, int nEventID, NFIDataList valueList) { mSelf = self; mnEventID = nEventID; mArgValueList = valueList; }
public abstract int FindFloat(int nCol, double value, ref NFIDataList varResult);
public override int FindRecordRow(NFGUID self, string strRecordName, int nCol, NFVector3 nValue, ref NFIDataList xDatalist) { if (mhtObject.ContainsKey(self)) { NFIObject xGameObject = (NFIObject)mhtObject[self]; NFIRecord xRecord = xGameObject.GetRecordManager().GetRecord(strRecordName); if (null != xRecord) { return(xRecord.FindVector3(nCol, nValue, ref xDatalist)); } } return(-1); }
public abstract int FindString(int nCol, string value, ref NFIDataList varResult);
public override NFIObject CreateObject(NFGUID self, int nContainerID, int nGroupID, string strClassName, string strConfigIndex, NFIDataList arg) { if (!mhtObject.ContainsKey(self)) { NFIObject xNewObject = new NFCObject(self, nContainerID, nGroupID, strClassName, strConfigIndex); mhtObject.Add(self, xNewObject); NFCDataList varConfigID = new NFCDataList(); varConfigID.AddString(strConfigIndex); xNewObject.GetPropertyManager().AddProperty("ConfigID", varConfigID); NFCDataList varConfigClass = new NFCDataList(); varConfigClass.AddString(strClassName); xNewObject.GetPropertyManager().AddProperty("ClassName", varConfigClass); if (arg.Count() % 2 == 0) { for (int i = 0; i < arg.Count() - 1; i += 2) { string strPropertyName = arg.StringVal(i); NFIDataList.VARIANT_TYPE eType = arg.GetType(i + 1); switch (eType) { case NFIDataList.VARIANT_TYPE.VTYPE_INT: { NFIDataList xDataList = new NFCDataList(); xDataList.AddInt(arg.IntVal(i + 1)); xNewObject.GetPropertyManager().AddProperty(strPropertyName, xDataList); } break; case NFIDataList.VARIANT_TYPE.VTYPE_FLOAT: { NFIDataList xDataList = new NFCDataList(); xDataList.AddFloat(arg.FloatVal(i + 1)); xNewObject.GetPropertyManager().AddProperty(strPropertyName, xDataList); } break; case NFIDataList.VARIANT_TYPE.VTYPE_STRING: { NFIDataList xDataList = new NFCDataList(); xDataList.AddString(arg.StringVal(i + 1)); xNewObject.GetPropertyManager().AddProperty(strPropertyName, xDataList); } break; case NFIDataList.VARIANT_TYPE.VTYPE_OBJECT: { NFIDataList xDataList = new NFCDataList(); xDataList.AddObject(arg.ObjectVal(i + 1)); xNewObject.GetPropertyManager().AddProperty(strPropertyName, xDataList); } break; case NFIDataList.VARIANT_TYPE.VTYPE_VECTOR2: { NFIDataList xDataList = new NFCDataList(); xDataList.AddVector2(arg.Vector2Val(i + 1)); xNewObject.GetPropertyManager().AddProperty(strPropertyName, xDataList); } break; case NFIDataList.VARIANT_TYPE.VTYPE_VECTOR3: { NFIDataList xDataList = new NFCDataList(); xDataList.AddVector3(arg.Vector3Val(i + 1)); xNewObject.GetPropertyManager().AddProperty(strPropertyName, xDataList); } break; default: break; } } } InitProperty(self, strClassName); InitRecord(self, strClassName); ClassHandleDel xHandleDel = (ClassHandleDel)mhtClassHandleDel[strClassName]; if (null != xHandleDel && null != xHandleDel.GetHandler()) { NFIObject.ClassEventHandler xHandlerList = xHandleDel.GetHandler(); xHandlerList(self, nContainerID, nGroupID, NFIObject.CLASS_EVENT_TYPE.OBJECT_CREATE, strClassName, strConfigIndex); xHandlerList(self, nContainerID, nGroupID, NFIObject.CLASS_EVENT_TYPE.OBJECT_LOADDATA, strClassName, strConfigIndex); xHandlerList(self, nContainerID, nGroupID, NFIObject.CLASS_EVENT_TYPE.OBJECT_CREATE_FINISH, strClassName, strConfigIndex); } //NFCLog.Instance.Log(NFCLog.LOG_LEVEL.DEBUG, "Create object: " + self.ToString() + " ClassName: " + strClassName + " SceneID: " + nContainerID + " GroupID: " + nGroupID); return(xNewObject); } return(null); }
public abstract int FindVector3(int nCol, NFVector3 value, ref NFIDataList varResult);
public abstract void RegisterCallback(NFGUID self, int nEventID, NFIEvent.EventHandler handler, NFIDataList valueList);