Beispiel #1
0
 public CodeListRef(CodeList codeList, Id alias)
 {
     Id       = codeList.Id;
     AgencyId = codeList.AgencyId;
     Version  = codeList.Version;
     Alias    = alias;
 }
Beispiel #2
0
 public virtual bool TryParse(string s, string startTime, out object obj)
 {
     if (IsCoded)
     {
         var code = CodeList.Get(s);
         if (code == null)
         {
             obj = null;
             return(false);
         }
         obj = code.Id.ToString();
         return(true);
     }
     else
     {
         return(TextFormat.TryParse(s, startTime, out obj));
     }
 }
Beispiel #3
0
        public bool TrySerialize(object obj, out string s, out string startTime)
        {
            if (IsCoded)
            {
                var code = CodeList.Get(obj.ToString());
                if (code == null)
                {
                    s = startTime = null;
                    return(false);
                }

                s         = code.Id;
                startTime = null;
                return(true);
            }
            else
            {
                return(TextFormat.TrySerialize(obj, out s, out startTime));
            }
        }
Beispiel #4
0
        public void AddCodeList(CodeList codeList, Id alias)
        {
            Contract.AssertNotNull(codeList, "codeList");

            AddCodeList(new CodeListRef(codeList, alias));
        }
Beispiel #5
0
 public Dimension(Concept concept, CodeList codeList)
     : base(concept, codeList)
 {
 }
Beispiel #6
0
 public PrimaryMeasure(Concept concept, CodeList codeList)
     : base(concept, codeList)
 {
 }
Beispiel #7
0
 public CrossSectionalMeasure(Concept concept, CodeList codeList)
     : base(concept, codeList)
 {
 }
Beispiel #8
0
 public Attribute(Concept concept, CodeList codeList)
     : base(concept, codeList)
 {
 }
Beispiel #9
0
 public Component(Concept concept, CodeList codeList)
 {
     this.Concept    = concept;
     this.CodeList   = codeList;
     this.TextFormat = DefaultTextFormat;
 }