Esempio n. 1
0
 public Table(DbCommand command)
     : base(command)
 {
     children = new List<Table>();
     counter = CounterFactory.getInstance().getCounter(this.GetType());
     counter.IncrementCreatedCount();
 }
Esempio n. 2
0
        internal Counter getCounter(Type type)
        {
            Counter counter = Counter.getCounterForType(type);

            if (counter == null) {

                lock (factoryLock) {

                    counter = Counter.getCounterForType(type);

                    if (counter == null) {

                        counter = new Counter();
                    }
                }
            }

            return counter;
        }