示例#1
0
 public void Buy(DepositContent content, MarketState marketstate, int stockstobuy)
 {
     try
     {
         Deposit.Buy(content, marketstate, stockstobuy);
     }
     catch (System.Exception ex)
     {
         throw ex;
     }
 }
示例#2
0
 public void Sell(DepositContent content, MarketState marketstate, int stockstosell)
 {
     try
     {
         Deposit.Sell(content, marketstate, stockstosell);
     }
     catch (System.Exception ex)
     {
         throw ex;
     }
 }
示例#3
0
 public void ClientBuyingStocks(Version clientversion, ICommunicateable communicator, string stockid, Player player)
 {
     try
     {
         if (clientversion.Major > 0)
         {
             lock (SynchronizeRoot)
             {
                 DepositContent content = null;
                 if (player.Deposit.TryGetValue(stockid, out content))
                 {
                     content.ServerBuyStocks(clientversion, communicator);
                 }
             }
         }
     }
     catch (System.Exception ex)
     {
         throw ex;
     }
 }