Ejemplo n.º 1
0
 /// <summary>
 /// Transaction object for atomic operations
 /// </summary>
 /// <returns></returns>
 public static DwarfTransaction Atomic( Command cmd )
 {
     return new DwarfTransaction( cmd );
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Add new command into a commands queue
 /// </summary>
 /// <param name="cmd"></param>
 public void AddCommand( Command cmd )
 {
     if ( !is_atomic && commands_chain.Count == 0 )
         commands_chain.Enqueue(cmd);
 }
Ejemplo n.º 3
0
 public DwarfTransaction( Command cmd )
 {
     AddCommand( cmd );
 }