src/Tools/jEdit/src/proofdocument/session.scala
changeset 34810 9ad3431a34a5
parent 34809 0fed930f2992
child 34813 f0107bc96961
equal deleted inserted replaced
34809:0fed930f2992 34810:9ad3431a34a5
    31 
    31 
    32   private var id_count: BigInt = 0
    32   private var id_count: BigInt = 0
    33   def create_id(): String = synchronized { id_count += 1; "j" + id_count }
    33   def create_id(): String = synchronized { id_count += 1; "j" + id_count }
    34 
    34 
    35 
    35 
    36   /* document state information -- vars belong to session_actor */
    36   /* document state information -- owned by session_actor */
    37 
    37 
    38   @volatile private var outer_syntax = new Outer_Syntax(system.symbols)
    38   @volatile private var outer_syntax = new Outer_Syntax(system.symbols)
    39   def syntax(): Outer_Syntax = outer_syntax
    39   def syntax(): Outer_Syntax = outer_syntax
    40 
    40 
    41   @volatile private var states = Map[Isar_Document.State_ID, Command_State]()
    41   @volatile private var states = Map[Isar_Document.State_ID, Command_State]()
   182   def stop() { session_actor ! Stop }
   182   def stop() { session_actor ! Stop }
   183   def input(change: Change) { session_actor ! change }
   183   def input(change: Change) { session_actor ! change }
   184 
   184 
   185   def begin_document(path: String): Proof_Document =
   185   def begin_document(path: String): Proof_Document =
   186     (session_actor !? Begin_Document(path)).asInstanceOf[Proof_Document]
   186     (session_actor !? Begin_Document(path)).asInstanceOf[Proof_Document]
   187 
       
   188 
       
   189   /* selected state */  // FIXME eliminate!?!
       
   190 
       
   191   private var _selected_state: Command = null
       
   192   def selected_state = _selected_state
       
   193   def selected_state_=(state: Command) { _selected_state = state; results.event(state) }
       
   194 }
   187 }