コード例 #1
0
        public AuditSecurityAlertParticipantObject(ParticipantObjectTypeCodeRoleEnum role, ParticipantObjectIDTypeCode objectIdType, string participantObjectId)
        {
            Platform.CheckForNullReference(participantObjectId, "participantObjectId");

            ParticipantObjectTypeCode         = ParticipantObjectTypeCodeEnum.SystemObject;
            ParticipantObjectTypeCodeRole     = role;
            ParticipantObjectIdTypeCodedValue = objectIdType;
            _participantObjectId = participantObjectId;
        }
コード例 #2
0
        public ParticipantObjectIdentificationContents(ParticipantObjectTypeCodeEnum?type,
                                                       ParticipantObjectTypeCodeRoleEnum?role,
                                                       ParticipantObjectDataLifeCycleEnum?lifeCycle,
                                                       string participantObjectId,
                                                       ParticipantObjectIdTypeCodeEnum typeCode)
        {
            if (type.HasValue)
            {
                ParticipantObjectTypeCode          = (ParticipantObjectIdentificationContentsParticipantObjectTypeCode)type.Value;
                ParticipantObjectTypeCodeSpecified = true;
            }
            else
            {
                ParticipantObjectTypeCodeSpecified = false;
            }

            if (role.HasValue)
            {
                ParticipantObjectTypeCodeRole          = (ParticipantObjectIdentificationContentsParticipantObjectTypeCodeRole)role.Value;
                ParticipantObjectTypeCodeRoleSpecified = true;
            }
            else
            {
                ParticipantObjectTypeCodeRoleSpecified = false;
            }

            if (lifeCycle.HasValue)
            {
                ParticipantObjectDataLifeCycle          = (ParticipantObjectIdentificationContentsParticipantObjectDataLifeCycle)lifeCycle.Value;
                ParticipantObjectDataLifeCycleSpecified = true;
            }
            else
            {
                ParticipantObjectDataLifeCycleSpecified = false;
            }

            ParticipantObjectID = participantObjectId;

            ParticipantObjectIDTypeCode = new ParticipantObjectIDTypeCode(typeCode);
        }
コード例 #3
0
        public ParticipantObjectIdentificationContents(AuditParticipantObject item)
        {
            if (item.ParticipantObjectTypeCode.HasValue)
            {
                ParticipantObjectTypeCode          = (ParticipantObjectIdentificationContentsParticipantObjectTypeCode)item.ParticipantObjectTypeCode.Value;
                ParticipantObjectTypeCodeSpecified = true;
            }
            else
            {
                ParticipantObjectTypeCodeSpecified = false;
            }

            if (item.ParticipantObjectTypeCodeRole.HasValue)
            {
                ParticipantObjectTypeCodeRole          = (ParticipantObjectIdentificationContentsParticipantObjectTypeCodeRole)item.ParticipantObjectTypeCodeRole.Value;
                ParticipantObjectTypeCodeRoleSpecified = true;
            }
            else
            {
                ParticipantObjectTypeCodeRoleSpecified = false;
            }

            if (item.ParticipantObjectDataLifeCycle.HasValue)
            {
                ParticipantObjectDataLifeCycle          = (ParticipantObjectIdentificationContentsParticipantObjectDataLifeCycle)item.ParticipantObjectDataLifeCycle.Value;
                ParticipantObjectDataLifeCycleSpecified = true;
            }
            else
            {
                ParticipantObjectDataLifeCycleSpecified = false;
            }

            if (item.ParticipantObjectIdTypeCode.HasValue)
            {
                ParticipantObjectIDTypeCode =
                    new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCode.Value);
            }
            else if (item.ParticipantObjectIdTypeCodedValue != null)
            {
                ParticipantObjectIDTypeCode =
                    new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCodedValue);
            }

            if (item.ParticipantObjectDetail != null)
            {
                ParticipantObjectDetail = new[] { item.ParticipantObjectDetail }
            }
            ;

            if (!string.IsNullOrEmpty(item.ParticipantObjectDetailString))
            {
                ParticipantObjectDetail = new ParticipantObjectDetail[] { new ParticipantObjectDetail()
                                                                          {
                                                                              type = item.ParticipantObjectDetailString
                                                                          } };
            }

            if (!string.IsNullOrEmpty(item.ParticipantObjectId))
            {
                ParticipantObjectID = item.ParticipantObjectId;
            }

            if (!string.IsNullOrEmpty(item.ParticipantObjectName))
            {
                Item = item.ParticipantObjectName;
            }

            if (item.ParticipantObjectQuery != null)
            {
                Item = item.ParticipantObjectQuery;
            }

            if (!String.IsNullOrEmpty(item.AccessionNumber))
            {
                Accession = new[] { new ParticipantObjectDescriptionTypeAccession(item.AccessionNumber) }
            }
            ;
            if (!String.IsNullOrEmpty(item.MppsUid))
            {
                MPPS = new[] { new ParticipantObjectDescriptionTypeMPPS(item.MppsUid) }
            }
            ;

            if (item.SopClassDictionary != null && item.SopClassDictionary.Count > 0)
            {
                // TODO: right now the schema only allows one SOP Class. It nees to be fixed.
                var sopClass = CollectionUtils.FirstElement(item.SopClassDictionary.Values);
                SOPClass = new ParticipantObjectDescriptionTypeSOPClass(sopClass.UID, sopClass.NumberOfInstances);
            }
        }
    }
コード例 #4
0
        public ParticipantObjectIdentificationContents(AuditParticipantObject item)
        {
            if (item.ParticipantObjectTypeCode.HasValue)
            {
                ParticipantObjectTypeCode          = (ParticipantObjectIdentificationContentsParticipantObjectTypeCode)item.ParticipantObjectTypeCode.Value;
                ParticipantObjectTypeCodeSpecified = true;
            }
            else
            {
                ParticipantObjectTypeCodeSpecified = false;
            }

            if (item.ParticipantObjectTypeCodeRole.HasValue)
            {
                ParticipantObjectTypeCodeRole          = (ParticipantObjectIdentificationContentsParticipantObjectTypeCodeRole)item.ParticipantObjectTypeCodeRole.Value;
                ParticipantObjectTypeCodeRoleSpecified = true;
            }
            else
            {
                ParticipantObjectTypeCodeRoleSpecified = false;
            }

            if (item.ParticipantObjectDataLifeCycle.HasValue)
            {
                ParticipantObjectDataLifeCycle          = (ParticipantObjectIdentificationContentsParticipantObjectDataLifeCycle)item.ParticipantObjectDataLifeCycle.Value;
                ParticipantObjectDataLifeCycleSpecified = true;
            }
            else
            {
                ParticipantObjectDataLifeCycleSpecified = false;
            }

            if (item.ParticipantObjectIdTypeCode.HasValue)
            {
                ParticipantObjectIDTypeCode =
                    new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCode.Value);
            }
            else if (item.ParticipantObjectIdTypeCodedValue != null)
            {
                ParticipantObjectIDTypeCode =
                    new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCodedValue);
            }

            if (item.ParticipantObjectDetail != null)
            {
                ParticipantObjectDetail = new[] { item.ParticipantObjectDetail }
            }
            ;

            if (!string.IsNullOrEmpty(item.ParticipantObjectDetailString))
            {
                ParticipantObjectDetail = new ParticipantObjectDetail[] { new ParticipantObjectDetail()
                                                                          {
                                                                              type = item.ParticipantObjectDetailString
                                                                          } };
            }

            if (!string.IsNullOrEmpty(item.ParticipantObjectId))
            {
                ParticipantObjectID = item.ParticipantObjectId;
            }

            if (!string.IsNullOrEmpty(item.ParticipantObjectName))
            {
                Item = item.ParticipantObjectName;
            }

            if (item.ParticipantObjectQuery != null)
            {
                Item = item.ParticipantObjectQuery;
            }

            if (!String.IsNullOrEmpty(item.AccessionNumber))
            {
                Accession = new[] { new ParticipantObjectDescriptionTypeAccession(item.AccessionNumber) }
            }
            ;
            if (!String.IsNullOrEmpty(item.MppsUid))
            {
                MPPS = new[] { new ParticipantObjectDescriptionTypeMPPS(item.MppsUid) }
            }
            ;

            if (item.SopClassDictionary != null && item.SopClassDictionary.Count > 0)
            {
                SOPClass = item.SopClassDictionary.Values.Select(sopClass => new ParticipantObjectDescriptionTypeSOPClass(sopClass.UID, sopClass.NumberOfInstances)).ToArray();
            }
        }
    }
コード例 #5
0
        public ParticipantObjectIdentificationContents(AuditParticipantObject item)
		{
			if (item.ParticipantObjectTypeCode.HasValue)
			{
                ParticipantObjectTypeCode = (ParticipantObjectIdentificationContentsParticipantObjectTypeCode)item.ParticipantObjectTypeCode.Value;
				ParticipantObjectTypeCodeSpecified = true;
			}
			else ParticipantObjectTypeCodeSpecified = false;

			if (item.ParticipantObjectTypeCodeRole.HasValue)
			{
                ParticipantObjectTypeCodeRole = (ParticipantObjectIdentificationContentsParticipantObjectTypeCodeRole)item.ParticipantObjectTypeCodeRole.Value;
				ParticipantObjectTypeCodeRoleSpecified = true;
			}
			else
				ParticipantObjectTypeCodeRoleSpecified = false;

			if (item.ParticipantObjectDataLifeCycle.HasValue)
			{
                ParticipantObjectDataLifeCycle = (ParticipantObjectIdentificationContentsParticipantObjectDataLifeCycle)item.ParticipantObjectDataLifeCycle.Value;
				ParticipantObjectDataLifeCycleSpecified = true;
			}
			else
				ParticipantObjectDataLifeCycleSpecified = false;

			if (item.ParticipantObjectIdTypeCode.HasValue)
			{
				ParticipantObjectIDTypeCode =
					new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCode.Value);
			}
			else if (item.ParticipantObjectIdTypeCodedValue != null)
			{
				ParticipantObjectIDTypeCode =
                    new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCodedValue);
			}

			if (item.ParticipantObjectDetail != null)
				ParticipantObjectDetail = new[] {item.ParticipantObjectDetail};

			if (!string.IsNullOrEmpty(item.ParticipantObjectDetailString))
			{
                ParticipantObjectDetail = new ParticipantObjectDetail[] { new ParticipantObjectDetail() {type = item.ParticipantObjectDetailString }};
			}

			if (!string.IsNullOrEmpty(item.ParticipantObjectId))
				ParticipantObjectID = item.ParticipantObjectId;

			if (!string.IsNullOrEmpty(item.ParticipantObjectName))
				Item = item.ParticipantObjectName;

			if (item.ParticipantObjectQuery != null)
				Item = item.ParticipantObjectQuery;

			if (!String.IsNullOrEmpty(item.AccessionNumber))
				Accession = new[] { new ParticipantObjectDescriptionTypeAccession(item.AccessionNumber) };
			if (!String.IsNullOrEmpty(item.MppsUid))
                MPPS = new[] { new ParticipantObjectDescriptionTypeMPPS(item.MppsUid) };

			if (item.SopClassDictionary != null && item.SopClassDictionary.Count > 0)
			{
                // TODO: right now the schema only allows one SOP Class. It nees to be fixed.
                var sopClass = CollectionUtils.FirstElement(item.SopClassDictionary.Values);
                SOPClass = new ParticipantObjectDescriptionTypeSOPClass(sopClass.UID,sopClass.NumberOfInstances);
			}
		}
コード例 #6
0
		public ParticipantObjectIdentificationContents(ParticipantObjectTypeCodeEnum? type, 
			ParticipantObjectTypeCodeRoleEnum? role,
			ParticipantObjectDataLifeCycleEnum? lifeCycle, 
			string participantObjectId, 
			ParticipantObjectIdTypeCodeEnum typeCode)
		{
			if (type.HasValue)
			{
				ParticipantObjectTypeCode = (ParticipantObjectIdentificationContentsParticipantObjectTypeCode)type.Value;
				ParticipantObjectTypeCodeSpecified = true;
			}
			else ParticipantObjectTypeCodeSpecified = false;

			if (role.HasValue)
			{
				ParticipantObjectTypeCodeRole = (ParticipantObjectIdentificationContentsParticipantObjectTypeCodeRole)role.Value;
				ParticipantObjectTypeCodeRoleSpecified = true;
			}
			else
				ParticipantObjectTypeCodeRoleSpecified = false;

			if (lifeCycle.HasValue)
			{
				ParticipantObjectDataLifeCycle = (ParticipantObjectIdentificationContentsParticipantObjectDataLifeCycle)lifeCycle.Value;
				ParticipantObjectDataLifeCycleSpecified = true;
			}
			else
				ParticipantObjectDataLifeCycleSpecified = false;

			ParticipantObjectID = participantObjectId;

			ParticipantObjectIDTypeCode = new ParticipantObjectIDTypeCode(typeCode);
		}
コード例 #7
0
ファイル: AuditParticipantObject.cs プロジェクト: nhannd/Xian
        public AuditSecurityAlertParticipantObject(ParticipantObjectTypeCodeRoleEnum role, ParticipantObjectIDTypeCode objectIdType, string participantObjectId)
        {
            Platform.CheckForNullReference(participantObjectId, "participantObjectId");

            ParticipantObjectTypeCode = ParticipantObjectTypeCodeEnum.SystemObject;
            ParticipantObjectTypeCodeRole = role;
            ParticipantObjectIdTypeCodedValue = objectIdType;
            _participantObjectId = participantObjectId;
        }
コード例 #8
0
        public ParticipantObjectIdentificationContents(AuditParticipantObject item)
		{
			if (item.ParticipantObjectTypeCode.HasValue)
			{
                ParticipantObjectTypeCode = (ParticipantObjectIdentificationContentsParticipantObjectTypeCode)item.ParticipantObjectTypeCode.Value;
				ParticipantObjectTypeCodeSpecified = true;
			}
			else ParticipantObjectTypeCodeSpecified = false;

			if (item.ParticipantObjectTypeCodeRole.HasValue)
			{
                ParticipantObjectTypeCodeRole = (ParticipantObjectIdentificationContentsParticipantObjectTypeCodeRole)item.ParticipantObjectTypeCodeRole.Value;
				ParticipantObjectTypeCodeRoleSpecified = true;
			}
			else
				ParticipantObjectTypeCodeRoleSpecified = false;

			if (item.ParticipantObjectDataLifeCycle.HasValue)
			{
                ParticipantObjectDataLifeCycle = (ParticipantObjectIdentificationContentsParticipantObjectDataLifeCycle)item.ParticipantObjectDataLifeCycle.Value;
				ParticipantObjectDataLifeCycleSpecified = true;
			}
			else
				ParticipantObjectDataLifeCycleSpecified = false;

			if (item.ParticipantObjectIdTypeCode.HasValue)
			{
				ParticipantObjectIDTypeCode =
					new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCode.Value);
			}
			else if (item.ParticipantObjectIdTypeCodedValue != null)
			{
				ParticipantObjectIDTypeCode =
                    new ParticipantObjectIDTypeCode(item.ParticipantObjectIdTypeCodedValue);
			}

			if (item.ParticipantObjectDetail != null)
				ParticipantObjectDetail = new[] {item.ParticipantObjectDetail};

			if (!string.IsNullOrEmpty(item.ParticipantObjectDetailString))
			{
                ParticipantObjectDetail = new ParticipantObjectDetail[] { new ParticipantObjectDetail() {type = item.ParticipantObjectDetailString }};
			}

			if (!string.IsNullOrEmpty(item.ParticipantObjectId))
				ParticipantObjectID = item.ParticipantObjectId;

			if (!string.IsNullOrEmpty(item.ParticipantObjectName))
				Item = item.ParticipantObjectName;

			if (item.ParticipantObjectQuery != null)
				Item = item.ParticipantObjectQuery;

			if (!String.IsNullOrEmpty(item.AccessionNumber))
				Accession = new[] { new ParticipantObjectDescriptionTypeAccession(item.AccessionNumber) };
			if (!String.IsNullOrEmpty(item.MppsUid))
                MPPS = new[] { new ParticipantObjectDescriptionTypeMPPS(item.MppsUid) };

			if (item.SopClassDictionary != null && item.SopClassDictionary.Count > 0)
			{
				SOPClass = item.SopClassDictionary.Values.Select(sopClass => new ParticipantObjectDescriptionTypeSOPClass(sopClass.UID, sopClass.NumberOfInstances)).ToArray();
			}
		}