示例#1
0
            //For subscribe registrations
            public MyListViewItem(Int64 typeId, Safir.Dob.Typesystem.HandlerId handlerId, bool includeSubClasses, bool restartSubscription)
            {
                this.Text = Safir.Dob.Typesystem.Operations.GetName(typeId);

                this.typeId              = typeId;
                this.handlerId           = handlerId;
                this.includeSubClasses   = includeSubClasses;
                this.restartSubscription = restartSubscription;

                this.SubItems.Add(handlerId.ToString());

                string subscrStr = "";
                bool   slash     = false;

                if (includeSubClasses)
                {
                    if (slash)
                    {
                        subscrStr += " / ";
                    }
                    subscrStr += "subclasses";
                    slash      = true;
                }
                if (restartSubscription)
                {
                    if (slash)
                    {
                        subscrStr += " / ";
                    }
                    subscrStr += "restart";
                    slash      = true;
                }
                this.SubItems.Add(subscrStr);
            }
示例#2
0
            //For register
            public MyListViewItem(Int64 typeId, Safir.Dob.Typesystem.HandlerId handlerId, bool pending, bool injection, bool requestorDecides)
            {
                this.Text             = Safir.Dob.Typesystem.Operations.GetName(typeId);
                this.typeId           = typeId;
                this.handlerId        = handlerId;
                this.pending          = pending;
                this.injection        = injection;
                this.requestorDecides = requestorDecides;

                this.SubItems.Add(handlerId.ToString());
                if (pending)
                {
                    this.SubItems.Add("yes");
                }
                else
                {
                    this.SubItems.Add("no");
                }
                if (injection)
                {
                    this.SubItems.Add("yes");
                }
                else
                {
                    this.SubItems.Add("no");
                }
                if (requestorDecides)
                {
                    this.SubItems.Add("Requestor");
                }
                else
                {
                    this.SubItems.Add("Handler");
                }
            }
示例#3
0
 //
 // The following methods are derived from Safir.Dob.ServiceHandler.
 //
 public void OnRevokedRegistration(long typeId, Safir.Dob.Typesystem.HandlerId handlerId)
 {
     // No longer registered for given type.
     Safir.Logging.SendSystemLog(Safir.Logging.Severity.Critical,
                                 "Unexpected revoked registration. " +
                                 handlerId.ToString() + " is no longer registered for type " +
                                 Safir.Dob.Typesystem.Operations.GetName(typeId));
 }
示例#4
0
 void Safir.Dob.RevokedRegistrationBase.OnRevokedRegistration(long typeId, Safir.Dob.Typesystem.HandlerId handlerId)
 {
     if (m_isActive)
     {
         Logger.Instance.WriteLine("Deactivating");
         m_testConnection.Close();
         m_controlConnection.UnregisterHandler(m_partnerEntityId.TypeId, new Safir.Dob.Typesystem.HandlerId(m_instance));
         m_controlConnection.UnregisterHandler(DoseTest.Dump.ClassTypeId, new Safir.Dob.Typesystem.HandlerId(m_instance));
         m_isActive = false;
     }
 }
 public HandlerIdSerializeable(Safir.Dob.Typesystem.HandlerId handlerId)
 {
     m_handlerId    = handlerId.RawValue;
     m_handlerIdStr = handlerId.RawString;
 }
 public void setHandlerId(Safir.Dob.Typesystem.HandlerId handlerId)
 {
     handlerIdSer = new HandlerIdSerializeable(handlerId);
 }
 public void OnInitialInjectionsDone(
     long typeId, Safir.Dob.Typesystem.HandlerId handlerId)
 {
     // This is just notification - no actions need to be taken.
 }