Пример #1
0
        public sc2i.common.CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            CResultAErreur result = CResultAErreur.True;

            result.EmpileErreur("Partial mib module tree serialization is not implemented");
            return(result);
        }
Пример #2
0
        /// ///////////////////////////////////////////////
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = base.MySerialize(serializer);
            if (!result)
            {
                return(result);
            }

            if (nVersion < 1 && serializer.Mode == ModeSerialisation.Lecture)
            {
                int nIdTemp = -1;
                serializer.TraiteInt(ref nIdTemp);
                m_strIdVariableForResult = nIdTemp.ToString();
            }
            else
            {
                serializer.TraiteString(ref m_strIdVariableForResult);
            }

            return(result);
        }
Пример #3
0
        //-------------------------------------------------
        protected override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strIdUniverselLien);
            if (serializer.Mode == ModeSerialisation.Lecture)
            {
                m_lien = null;
                m_strIdUniverselDest   = "";
                m_strIdUniverselSource = "";
            }
            int nCol = m_couleurLien.ToArgb();

            serializer.TraiteInt(ref nCol);
            m_couleurLien = Color.FromArgb(nCol);

            serializer.TraiteInt(ref m_nEpaisseurLien);

            if (nVersion >= 1)
            {
                int nModeSortie = (int)m_modeSortie;
                serializer.TraiteInt(ref nModeSortie);
                m_modeSortie = (EModeSortieLien)nModeSortie;
            }

            return(result);
        }
Пример #4
0
        /// //////////////////////////////////////////////////////////////
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            int nX, nY;

            nX = m_lastPointArrivee.X;
            nY = m_lastPointArrivee.Y;
            serializer.TraiteInt(ref nX);
            serializer.TraiteInt(ref nY);
            m_lastPointArrivee.X = nX;
            m_lastPointArrivee.Y = nY;

            nX = m_lastPointDepart.X;
            nY = m_lastPointDepart.Y;
            serializer.TraiteInt(ref nX);
            serializer.TraiteInt(ref nY);
            m_lastPointDepart.X = nX;
            m_lastPointDepart.Y = nY;

            return(result);
        }
Пример #5
0
        //---------------------------------------------------------------
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            return(result);
        }
Пример #6
0
        //---------------------------------------------------------
        public CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            return(result);
        }
Пример #7
0
        //----------------------------------------
        protected override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = base.MySerialize(serializer);
            if (!result)
            {
                return(result);
            }

            int nCol = BackColor.ToArgb();

            serializer.TraiteInt(ref nCol);
            m_backColor = Color.FromArgb(nCol);

            nCol = ForeColor.ToArgb();
            serializer.TraiteInt(ref nCol);
            m_foreColor = Color.FromArgb(nCol);

            int nBorder = (int)BorderStyle;

            serializer.TraiteInt(ref nBorder);
            BorderStyle = (EBorderStyle)nBorder;

            result = serializer.TraiteListe <I2iObjetGraphique>(m_listeChilds);

            return(result);
        }
Пример #8
0
        //------------------------------------------------
        public virtual CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strImageKey);
            result = serializer.TraiteListe <IColumnDefinition>(m_listeColonnes);
            if (!result)
            {
                return(result);
            }
            foreach (IColumnDefinition col in m_listeColonnes)
            {
                col.Table = this;
            }
            if (nVersion >= 1)
            {
                serializer.TraiteString(ref m_strSourceId);
            }

            return(result);
        }
Пример #9
0
        //-------------------------------------------------------
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = SerializeChamps(serializer,
                                     c_champPresence,
                                     CEquipement.c_champSerial,
                                     CEquipement.c_champId,
                                     CTypeEquipement.c_champId,
                                     CTypeEquipementConstructeur.c_champId,
                                     CEquipement.c_champCoordonnee,
                                     c_champCommentaire);

            if (result)
            {
                result = SerializeParent <CReleveSite>(serializer);
            }
            if (result)
            {
                result = SerializeParent <CReleveEquipement>(serializer, c_champIdContenant);
            }
            return(result);
        }
Пример #10
0
        //------------------------------------------------------
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strIdUniverselEtape);
            if (serializer.Mode == ModeSerialisation.Lecture && m_strIdUniverselEtape.Length > 0)
            {
                serializer.TrackDbKeyReaded(m_strIdUniverselEtape);
            }
            if (serializer.Mode == ModeSerialisation.Lecture)
            {
                m_typeEtape = null;
            }

            int nCol = m_backColor.ToArgb();

            serializer.TraiteInt(ref nCol);
            m_backColor = Color.FromArgb(nCol);

            nCol = m_foreColor.ToArgb();
            serializer.TraiteInt(ref nCol);
            m_foreColor = Color.FromArgb(nCol);


            return(result);
        }
Пример #11
0
        //---------------------------------------------
        public CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }

            serializer.TraiteString(ref m_strLibelle);

            result = serializer.TraiteObject <CEasyQuery>(ref m_query);
            if (result)
            {
                result = serializer.TraiteObject <CListeQuerySource>(ref m_listeSources);
            }
            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strNomTableSource);
            serializer.TraiteString(ref m_strChampCleElement);
            serializer.TraiteString(ref m_strChampLatitude);
            serializer.TraiteString(ref m_strChampLongitude);
            serializer.TraiteString(ref m_strChampLibelle);
            serializer.TraiteDouble(ref m_fMetresEntrePoints);
            return(result);
        }
Пример #12
0
        /// //////////////////////////////////////////////////////////////
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteInt(ref m_nIdActionArrivee);
            serializer.TraiteInt(ref m_nIdActionDepart);
            int nX, nY;

            AssurePositionOk();

            nX = m_lastPointArrivee.X;
            nY = m_lastPointArrivee.Y;
            serializer.TraiteInt(ref nX);
            serializer.TraiteInt(ref nY);
            m_lastPointArrivee.X = nX;
            m_lastPointArrivee.Y = nY;

            nX = m_lastPointDepart.X;
            nY = m_lastPointDepart.Y;
            serializer.TraiteInt(ref nX);
            serializer.TraiteInt(ref nY);
            m_lastPointDepart.X = nX;
            m_lastPointDepart.Y = nY;

            if (nVersion > 0)
            {
                serializer.TraiteInt(ref m_nId);
            }
            else
            {
                if (m_process != null)
                {
                    m_nId = m_process.GetIdNouvelObjetDeProcess();
                }
                else
                {
                    m_nId = -1;
                }
            }

            if (nVersion >= 2)
            {
                int nTmp = (int)m_modeSortie;
                serializer.TraiteInt(ref nTmp);
                m_modeSortie = (EModeSortieLien)nTmp;
            }
            if (serializer.Mode == ModeSerialisation.Lecture)
            {
                m_bPositionInvalide = true;
            }

            return(result);
        }
Пример #13
0
        //---------------------------------------------------
        public override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = base.MySerialize(serializer);
            if (!result)
            {
                return(result);
            }

            if (nVersion < 3)
            {
                // TESTDBKEYTODO
                serializer.ReadDbKeyFromOldId(ref m_dbKeyTypeProjet, typeof(CTypeProjet));
            }
            else
            {
                serializer.TraiteDbKey(ref m_dbKeyTypeProjet);
            }

            int nId = m_nIdChampProjet == null ? -1 : m_nIdChampProjet.Value;

            serializer.TraiteInt(ref nId);
            if (serializer.Mode == ModeSerialisation.Lecture)
            {
                m_nIdChampProjet = nId >= 0 ? (int?)nId : null;
            }

            result = serializer.TraiteListe <CAffectationsProprietes>(m_listeAffectations);
            if (!result)
            {
                return(result);
            }

            if (nVersion >= 1)
            {
                result = serializer.TraiteObject <C2iExpression>(ref m_formuleGanttId);
            }
            if (!result)
            {
                return(result);
            }
            if (nVersion >= 2)
            {
                serializer.TraiteBool(ref m_bGererIterations);
            }

            return(result);
        }
        //-------------------------------------------------------------------------------------------
        public override sc2i.common.CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (result)
            {
                result = base.Serialize(serializer);
            }
            return(result);
        }
Пример #15
0
        public sc2i.common.CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteType(ref m_typeDonnees);
            serializer.TraiteString(ref m_strNom);
            return(result);
        }
Пример #16
0
        //-------------------------------------------------------
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = SerializeChamps(serializer, CSite.c_champId, c_champDate);

            /*if (result)
             *  result = SerializeChilds<CReleveEquipement>(serializer);*/
            return(result);
        }
Пример #17
0
        //------------------------------------------------------
        protected override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = serializer.TraiteObject <CChartSetup>(ref m_parametreChart);
            if (!result)
            {
                return(result);
            }
            return(result);
        }
Пример #18
0
        //---------------------------------------------------
        protected override sc2i.common.CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = this.GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = base.MySerialize(serializer);
            if (!result)
            {
                return(result);
            }
            return(result);
        }
Пример #19
0
        //---------------------------------------
        protected override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = SerializeChamps(serializer, c_champLabel, c_champIdTypeDonneeCumulee, c_champFrequenceMinutes, c_champParametresRemplisssage);
            if (result)
            {
                result = SerializeParent <CAgentSnmpPourSupervision>(serializer);
            }
            return(result);
        }
Пример #20
0
        //---------------------------------------------------
        public override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = serializer.TraiteObject <CParametreDeclencheurEvenement>(ref m_parametreDeclencheur);
            if (result)
            {
                result = serializer.TraiteObject <C2iExpression>(ref m_formuleElementDeclencheur);
            }
            return(result);
        }
Пример #21
0
        //-------------------------------------------------
        protected override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            if (result)
            {
                result = SerializeChamps(serializer,
                                         c_champNom,
                                         c_champType);
            }
            return(result);
        }
Пример #22
0
        //---------------------------------------------------
        public override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = serializer.TraiteListe <CFormuleNommee>(m_listeFormulesCodesRetour);
            if (!result)
            {
                return(result);
            }

            return(result);
        }
Пример #23
0
        //----------------------------------------------
        public override sc2i.common.CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = base.Serialize(serializer);
            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strHotelColumnId);
            return(result);
        }
        //---------------------------------------------------------------
        protected override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (result)
            {
                result = base.MySerialize(serializer);
            }
            if (!result)
            {
                return(result);
            }

            result = SerializeParent <CEquipement>(serializer);
            return(result);
        }
Пример #25
0
        //-------------------------------------------
        public override sc2i.common.CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = base.Serialize(serializer);
            if (!result)
            {
                return(result);
            }
            result = serializer.TraiteObject <CFiltreDynamique>(ref m_filtreDynamique);
            return(result);
        }
        public override CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            result = base.Serialize(serializer);
            if (!result)
            {
                return(result);
            }
            serializer.TraiteInt(ref m_nEspaceGraduations);

            int nTmp = (int)m_orientation;

            serializer.TraiteInt(ref nTmp);
            m_orientation = (EGraduationOrientation)nTmp;

            nTmp = (int)m_HorizontalAlignment;
            serializer.TraiteInt(ref nTmp);
            m_HorizontalAlignment = (E3DAlignement)nTmp;

            nTmp = (int)m_VerticalAlignment;
            serializer.TraiteInt(ref nTmp);
            m_VerticalAlignment = (E3DAlignement)nTmp;

            nTmp = (int)DepthAlignment;
            serializer.TraiteInt(ref nTmp);
            m_DepthAlignment = (E3DAlignement)nTmp;

            nTmp = (int)m_faceAlignement;
            serializer.TraiteInt(ref nTmp);
            m_faceAlignement = (EFaceVueDynamique)nTmp;

            if (nVersion > 0)
            {
                string strTmp = AssociatedCoordinatePrefixes;
                serializer.TraiteString(ref strTmp);
                AssociatedCoordinatePrefixes = strTmp;
            }

            return(result);
        }
Пример #27
0
        //---------------------------------------------------
        public override CResultAErreur MySerialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strCleStepToStop);

            int nAction = (int)TypeAction;

            serializer.TraiteInt(ref nAction);
            TypeAction = (ETypeActionExterneOnWorkflowStep)nAction;

            return(result);
        }
        //-------------------------------------------------------------------
        public CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strIdSource);
            serializer.TraiteString(ref m_strTableName);
            serializer.TraiteString(ref m_strColumnName);
            if (nVersion >= 1)
            {
                serializer.TraiteObject <C2iExpression>(ref m_formule);
            }
            return(result);
        }
        //-------------------------------------------------------------------
        public CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }
            serializer.TraiteString(ref m_strIdSource);
            result = serializer.TraiteObject <C2iExpression>(ref m_formule);
            if (!result)
            {
                return(result);
            }
            serializer.TraiteBool(ref m_bEvaluateOnEachSourceElement);
            return(result);
        }
        //------------------------------------------------
        public CResultAErreur Serialize(sc2i.common.C2iSerializer serializer)
        {
            int            nVersion = GetNumVersion();
            CResultAErreur result   = serializer.TraiteVersion(ref nVersion);

            if (!result)
            {
                return(result);
            }

            result = serializer.TraiteObject <CEasyQuery>(ref m_query);
            if (result)
            {
                result = serializer.TraiteObject <CListeQuerySource>(ref m_listeSources);
            }
            if (!result)
            {
                return(result);
            }
            int nNbTables = m_listeTablesARetourner.Count;

            serializer.TraiteInt(ref nNbTables);
            switch (serializer.Mode)
            {
            case ModeSerialisation.Ecriture:
                foreach (string strTable in m_listeTablesARetourner)
                {
                    string strTmp = strTable;
                    serializer.TraiteString(ref strTmp);
                }
                break;

            case ModeSerialisation.Lecture:
                m_listeTablesARetourner.Clear();
                for (int n = 0; n < nNbTables; n++)
                {
                    string strTmp = "";
                    serializer.TraiteString(ref strTmp);
                    m_listeTablesARetourner.Add(strTmp);
                }
                break;
            }
            return(result);
        }