public static BusinessCentralConnector GetEntocareBCConnector(bool Debug = false)
 {
     if (EntCon == null)
     {
         EntCon = new BusinessCentralConnector(APIs.EntocareBusinessCentralAPI, Debug);
     }
     return(EntCon);
 }
 //Factory methods for each of the API's
 public static BusinessCentralConnector GetMicrosoftBCConnector(bool Debug = false)
 {
     if (MsCon == null)
     {
         MsCon = new BusinessCentralConnector(APIs.MicrosoftBusinessCentralApi, Debug);
     }
     return(MsCon);
 }
            public ChangeListener(BusinessCentralConnector owner)
            {
                switch (owner.api)
                {
                case APIs.MicrosoftBusinessCentralApi:
                    this.ctx = owner.Mctx;
                    break;

                case APIs.EntocareBusinessCentralAPI:
                    this.ctx = owner.Ectx;
                    break;
                }
                this.collection = new DataServiceCollection <T>(ctx);
            }
 public ChangeListener(T obj, BusinessCentralConnector owner) : this(owner)
 {
     this.Add(obj);
 }