Inheritance: AbstractTaggedArrayTO
Ejemplo n.º 1
0
 public TaggedPatientAssociateArrays(IndexedHashtable t)
 {
     if (t.Count == 0)
     {
         return;
     }
     arrays = new TaggedPatientAssociateArray[t.Count];
     for (int i = 0; i < t.Count; i++)
     {
         if (t.GetValue(i) == null)
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i));
         }
         else if (MdwsUtils.isException(t.GetValue(i)))
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i), (Exception)t.GetValue(i));
         }
         else if (t.GetValue(i).GetType().IsArray)
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i), (PatientAssociate[])t.GetValue(i));
         }
         else
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i), (PatientAssociate)t.GetValue(i));
         }
     }
     count = t.Count;
 }
Ejemplo n.º 2
0
 public TaggedPatientAssociateArrays(IndexedHashtable t)
 {
     if (t.Count == 0)
     {
         return;
     }
     arrays = new TaggedPatientAssociateArray[t.Count];
     for (int i = 0; i < t.Count; i++)
     {
         if (t.GetValue(i) == null)
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i));
         }
         else if (MdwsUtils.isException(t.GetValue(i)))
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i), (Exception)t.GetValue(i));
         }
         else if (t.GetValue(i).GetType().IsArray)
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i), (PatientAssociate[])t.GetValue(i));
         }
         else
         {
             arrays[i] = new TaggedPatientAssociateArray((string)t.GetKey(i), (PatientAssociate)t.GetValue(i));
         }
     }
     count = t.Count;
 }
Ejemplo n.º 3
0
        internal TaggedPatientAssociateArray getPatientAssociates(AbstractConnection cxn, string dfn)
        {
            TaggedPatientAssociateArray result = new TaggedPatientAssociateArray();
            if (dfn == "")
            {
                result.fault = new FaultTO("Missing dfn");
            }
            if (result.fault != null)
            {
                return result;
            }

            try
            {
                PatientApi patientApi = new PatientApi();
                PatientAssociate[] pas = patientApi.getPatientAssociates(cxn, dfn);
                result = new TaggedPatientAssociateArray(cxn.DataSource.SiteId.Id, pas);
            }
            catch (Exception e)
            {
                result.fault = new FaultTO(e.Message);
            }
            return result;
        }