/// <summary>
        /// Creates the facade instance according to the configured type
        /// </summary>
        private static IExternalInterface CreateInstance()
        {
            IExternalInterface facade = (IExternalInterface)Activator.CreateInstance(
                LocalConfiguration.ExternalInterface.FacadeType);

            return(facade);
        }
Exemple #2
0
 public static IInstrumentSymbol GetSymbol(IDalSession session, ITradeableInstrument Instrument, IExternalInterface externalInterface)
 {
     List<ICriterion> expressions = new List<ICriterion>();
     expressions.Add(Expression.Eq("Instrument.Key", Instrument.Key));
     expressions.Add(Expression.Eq("ExternalInterface", externalInterface));
     IList result = session.GetList(typeof(InstrumentSymbol), expressions);
     return (result.Count > 0) ? (IInstrumentSymbol)result[0] : null;
 }
Exemple #3
0
 /// <summary>
 /// Creates the facade instance according to the configured type
 /// </summary>
 private static IExternalInterface CreateInstance()
 {
     try
     {
         IExternalInterface facade = (IExternalInterface)Activator.CreateInstance(LocalConfiguration.ExternalInterface.FacadeType);
         return(facade);
     }
     catch (TargetInvocationException ex) when(ex.InnerException != null)
     {
         throw ex.InnerException;
     }
 }
Exemple #4
0
 public InstrumentSymbol(IExternalInterface externalInterface, string externalSymbol, IInstrument instrument)
     : base(externalInterface, externalSymbol)
 {
     this.Instrument = instrument;
 }
Exemple #5
0
 public void CheckExternalInterface(IExternalInterface ex)
 {
     var x = ex.PositiveNumber;
 }
 public AdapterExternalToInternal(IExternalInterface obj)
 {
     _obj = obj;
 }
Exemple #7
0
 public ESBClient(String _HCode)
 {
     _ESBClient = new RequestWsProvider <IExternalInterface>(_HCode).ReqClient;
 }
Exemple #8
0
 public InstrumentSymbol(IExternalInterface externalInterface, string externalSymbol, IInstrument instrument)
     : base(externalInterface, externalSymbol)
 {
     this.Instrument = instrument;
 }