Exemple #1
0
        public AkamaiUniversalProvisionJobData(XmlElement node) : base(node)
        {
            foreach (XmlElement propertyNode in node.ChildNodes)
            {
                switch (propertyNode.Name)
                {
                case "streamId":
                    this._StreamId = ParseInt(propertyNode.InnerText);
                    continue;

                case "systemUserName":
                    this._SystemUserName = propertyNode.InnerText;
                    continue;

                case "systemPassword":
                    this._SystemPassword = propertyNode.InnerText;
                    continue;

                case "domainName":
                    this._DomainName = propertyNode.InnerText;
                    continue;

                case "dvrEnabled":
                    this._DvrEnabled = (DVRStatus)ParseEnum(typeof(DVRStatus), propertyNode.InnerText);
                    continue;

                case "dvrWindow":
                    this._DvrWindow = ParseInt(propertyNode.InnerText);
                    continue;

                case "primaryContact":
                    this._PrimaryContact = propertyNode.InnerText;
                    continue;

                case "secondaryContact":
                    this._SecondaryContact = propertyNode.InnerText;
                    continue;

                case "streamType":
                    this._StreamType = (AkamaiUniversalStreamType)StringEnum.Parse(typeof(AkamaiUniversalStreamType), propertyNode.InnerText);
                    continue;

                case "notificationEmail":
                    this._NotificationEmail = propertyNode.InnerText;
                    continue;
                }
            }
        }
 public AkamaiUniversalProvisionJobData(JToken node) : base(node)
 {
     if (node["streamId"] != null)
     {
         this._StreamId = ParseInt(node["streamId"].Value <string>());
     }
     if (node["systemUserName"] != null)
     {
         this._SystemUserName = node["systemUserName"].Value <string>();
     }
     if (node["systemPassword"] != null)
     {
         this._SystemPassword = node["systemPassword"].Value <string>();
     }
     if (node["domainName"] != null)
     {
         this._DomainName = node["domainName"].Value <string>();
     }
     if (node["dvrEnabled"] != null)
     {
         this._DvrEnabled = (DVRStatus)ParseEnum(typeof(DVRStatus), node["dvrEnabled"].Value <string>());
     }
     if (node["dvrWindow"] != null)
     {
         this._DvrWindow = ParseInt(node["dvrWindow"].Value <string>());
     }
     if (node["primaryContact"] != null)
     {
         this._PrimaryContact = node["primaryContact"].Value <string>();
     }
     if (node["secondaryContact"] != null)
     {
         this._SecondaryContact = node["secondaryContact"].Value <string>();
     }
     if (node["streamType"] != null)
     {
         this._StreamType = (AkamaiUniversalStreamType)StringEnum.Parse(typeof(AkamaiUniversalStreamType), node["streamType"].Value <string>());
     }
     if (node["notificationEmail"] != null)
     {
         this._NotificationEmail = node["notificationEmail"].Value <string>();
     }
 }
Exemple #3
0
 public LiveEntry(JToken node) : base(node)
 {
     if (node["offlineMessage"] != null)
     {
         this._OfflineMessage = node["offlineMessage"].Value <string>();
     }
     if (node["recordStatus"] != null)
     {
         this._RecordStatus = (RecordStatus)ParseEnum(typeof(RecordStatus), node["recordStatus"].Value <string>());
     }
     if (node["dvrStatus"] != null)
     {
         this._DvrStatus = (DVRStatus)ParseEnum(typeof(DVRStatus), node["dvrStatus"].Value <string>());
     }
     if (node["dvrWindow"] != null)
     {
         this._DvrWindow = ParseInt(node["dvrWindow"].Value <string>());
     }
     if (node["lastElapsedRecordingTime"] != null)
     {
         this._LastElapsedRecordingTime = ParseInt(node["lastElapsedRecordingTime"].Value <string>());
     }
     if (node["liveStreamConfigurations"] != null)
     {
         this._LiveStreamConfigurations = new List <LiveStreamConfiguration>();
         foreach (var arrayNode in node["liveStreamConfigurations"].Children())
         {
             this._LiveStreamConfigurations.Add(ObjectFactory.Create <LiveStreamConfiguration>(arrayNode));
         }
     }
     if (node["recordedEntryId"] != null)
     {
         this._RecordedEntryId = node["recordedEntryId"].Value <string>();
     }
     if (node["pushPublishEnabled"] != null)
     {
         this._PushPublishEnabled = (LivePublishStatus)ParseEnum(typeof(LivePublishStatus), node["pushPublishEnabled"].Value <string>());
     }
     if (node["publishConfigurations"] != null)
     {
         this._PublishConfigurations = new List <LiveStreamPushPublishConfiguration>();
         foreach (var arrayNode in node["publishConfigurations"].Children())
         {
             this._PublishConfigurations.Add(ObjectFactory.Create <LiveStreamPushPublishConfiguration>(arrayNode));
         }
     }
     if (node["firstBroadcast"] != null)
     {
         this._FirstBroadcast = ParseInt(node["firstBroadcast"].Value <string>());
     }
     if (node["lastBroadcast"] != null)
     {
         this._LastBroadcast = ParseInt(node["lastBroadcast"].Value <string>());
     }
     if (node["currentBroadcastStartTime"] != null)
     {
         this._CurrentBroadcastStartTime = ParseFloat(node["currentBroadcastStartTime"].Value <string>());
     }
     if (node["recordingOptions"] != null)
     {
         this._RecordingOptions = ObjectFactory.Create <LiveEntryRecordingOptions>(node["recordingOptions"]);
     }
     if (node["liveStatus"] != null)
     {
         this._LiveStatus = (EntryServerNodeStatus)ParseEnum(typeof(EntryServerNodeStatus), node["liveStatus"].Value <string>());
     }
     if (node["segmentDuration"] != null)
     {
         this._SegmentDuration = ParseInt(node["segmentDuration"].Value <string>());
     }
     if (node["explicitLive"] != null)
     {
         this._ExplicitLive = (NullableBoolean)ParseEnum(typeof(NullableBoolean), node["explicitLive"].Value <string>());
     }
     if (node["viewMode"] != null)
     {
         this._ViewMode = (ViewMode)ParseEnum(typeof(ViewMode), node["viewMode"].Value <string>());
     }
     if (node["recordingStatus"] != null)
     {
         this._RecordingStatus = (RecordingStatus)ParseEnum(typeof(RecordingStatus), node["recordingStatus"].Value <string>());
     }
     if (node["lastBroadcastEndTime"] != null)
     {
         this._LastBroadcastEndTime = ParseInt(node["lastBroadcastEndTime"].Value <string>());
     }
     if (node["broadcastTime"] != null)
     {
         this._BroadcastTime = ParseInt(node["broadcastTime"].Value <string>());
     }
 }
Exemple #4
0
        public LiveEntry(XmlElement node) : base(node)
        {
            foreach (XmlElement propertyNode in node.ChildNodes)
            {
                switch (propertyNode.Name)
                {
                case "offlineMessage":
                    this._OfflineMessage = propertyNode.InnerText;
                    continue;

                case "recordStatus":
                    this._RecordStatus = (RecordStatus)ParseEnum(typeof(RecordStatus), propertyNode.InnerText);
                    continue;

                case "dvrStatus":
                    this._DvrStatus = (DVRStatus)ParseEnum(typeof(DVRStatus), propertyNode.InnerText);
                    continue;

                case "dvrWindow":
                    this._DvrWindow = ParseInt(propertyNode.InnerText);
                    continue;

                case "lastElapsedRecordingTime":
                    this._LastElapsedRecordingTime = ParseInt(propertyNode.InnerText);
                    continue;

                case "liveStreamConfigurations":
                    this._LiveStreamConfigurations = new List <LiveStreamConfiguration>();
                    foreach (XmlElement arrayNode in propertyNode.ChildNodes)
                    {
                        this._LiveStreamConfigurations.Add(ObjectFactory.Create <LiveStreamConfiguration>(arrayNode));
                    }
                    continue;

                case "recordedEntryId":
                    this._RecordedEntryId = propertyNode.InnerText;
                    continue;

                case "pushPublishEnabled":
                    this._PushPublishEnabled = (LivePublishStatus)ParseEnum(typeof(LivePublishStatus), propertyNode.InnerText);
                    continue;

                case "publishConfigurations":
                    this._PublishConfigurations = new List <LiveStreamPushPublishConfiguration>();
                    foreach (XmlElement arrayNode in propertyNode.ChildNodes)
                    {
                        this._PublishConfigurations.Add(ObjectFactory.Create <LiveStreamPushPublishConfiguration>(arrayNode));
                    }
                    continue;

                case "firstBroadcast":
                    this._FirstBroadcast = ParseInt(propertyNode.InnerText);
                    continue;

                case "lastBroadcast":
                    this._LastBroadcast = ParseInt(propertyNode.InnerText);
                    continue;

                case "currentBroadcastStartTime":
                    this._CurrentBroadcastStartTime = ParseFloat(propertyNode.InnerText);
                    continue;

                case "recordingOptions":
                    this._RecordingOptions = ObjectFactory.Create <LiveEntryRecordingOptions>(propertyNode);
                    continue;

                case "liveStatus":
                    this._LiveStatus = (EntryServerNodeStatus)ParseEnum(typeof(EntryServerNodeStatus), propertyNode.InnerText);
                    continue;

                case "segmentDuration":
                    this._SegmentDuration = ParseInt(propertyNode.InnerText);
                    continue;

                case "explicitLive":
                    this._ExplicitLive = (NullableBoolean)ParseEnum(typeof(NullableBoolean), propertyNode.InnerText);
                    continue;

                case "viewMode":
                    this._ViewMode = (ViewMode)ParseEnum(typeof(ViewMode), propertyNode.InnerText);
                    continue;

                case "recordingStatus":
                    this._RecordingStatus = (RecordingStatus)ParseEnum(typeof(RecordingStatus), propertyNode.InnerText);
                    continue;

                case "lastBroadcastEndTime":
                    this._LastBroadcastEndTime = ParseInt(propertyNode.InnerText);
                    continue;
                }
            }
        }