Exemple #1
0
        public AttachObject GetOther(Attachment attachment = null)
        {
            if (attachment == null)
            {
                if (attachObjects.Count > 1)
                {
                    throw new System.InvalidOperationException("Specify an Attachment for GetOther() when the "
                                                               + "AttachPoint is connected to multiple Attachments");
                }
                if (attachObjects.Count == 0)
                {
                    return(null);
                }
                attachment = attachObjects[0].attachment;
            }
            AttachObject thisAO = GetAttachObject(attachment);

            return(thisAO.GetOther());
        }