Exemple #1
0
        public override bool Equals(object obj)
        {
            if (obj == null)
            {
                return(false);
            }
            FourCC fourCC = obj as FourCC;

            return(fourCC != null && this.m_value == fourCC.m_value);
        }
        public void LookupResource(FourCC programId, FourCC streamId, FourCC locale, ResourcesAPI.ResourceLookupCallback cb, object userContext)
        {
            ContentHandleRequest contentHandleRequest = new ContentHandleRequest();

            contentHandleRequest.SetProgramId(programId.GetValue());
            contentHandleRequest.SetStreamId(streamId.GetValue());
            contentHandleRequest.SetLocale(locale.GetValue());
            if (contentHandleRequest == null || !contentHandleRequest.IsInitialized)
            {
                base.ApiLog.LogWarning("Unable to create request for RPC call.");
                return;
            }
            RPCContext rPCContext = this.m_rpcConnection.QueueRequest(this.m_resourcesService.Id, 1, contentHandleRequest, new RPCContextDelegate(this.GetContentHandleCallback), 0);
            ResourcesAPIPendingState resourcesAPIPendingState = new ResourcesAPIPendingState()
            {
                Callback    = cb,
                UserContext = userContext
            };

            this.m_pendingLookups.Add(rPCContext.Header.Token, resourcesAPIPendingState);
            base.ApiLog.LogDebug("Lookup request sent. PID={0} StreamID={1} Locale={2}", new object[] { programId, streamId, locale });
        }
Exemple #3
0
 public bool Equals(FourCC other)
 {
     return(other != null && this.m_value == other.m_value);
 }
Exemple #4
0
 public void CopyFrom(FourCC other)
 {
     this.m_value = other.m_value;
 }