Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 


Quellcode-Bibliothek

© Kompilation durch diese Firma

[Weder Korrektheit noch Funktionsfähigkeit der Software werden zugesichert.]

Datei: .project   Sprache: JAVA

Original von: VDM©

package gui;

import java.io.Serializable;

import org.overture.interpreter.runtime.ValueException;
import org.overture.interpreter.values.Value;
import org.overture.interpreter.values.VoidValue;


public class Graphics implements Serializable  {

 private static final long serialVersionUID = 1L;
 transient Controller ctrl;
    Model model;
   
    public Value init() {
     ctrl = new Controller();
     model = ctrl.getModel();
        return new VoidValue();
    }

    public Value sleep(){
        try {
   Thread.sleep(500);
  } catch (InterruptedException e) {
   e.printStackTrace();
  }
     
        return new VoidValue();
    }
    
    public Value move(){
     model.move();
     
     return new VoidValue();
    }
    
    public Value busInRouteTo(Value busline, Value roadid, Value waypoint, Value time) {
     
     try {
      String road = roadid.stringValue(null);
      
      if(road.startsWith("<"))
      {
       road = road.substring(1, road.length()-1);
      }
      
      String wp = waypoint.stringValue(null);
      if(wp.startsWith("<"))
      {
          wp =  wp.substring(1, wp.length()-1);
      }

   model.busInRouteTo((int) busline.intValue(null), road , wp, (int)time.intValue(null));
  } catch (ValueException e) {
   e.printStackTrace();
  }
  
  return new VoidValue();
    }

    public Value passengerAtCentral(Value id, Value goal) throws ValueException{

     final Value temp = id;
     String wp = goal.stringValue(null);
  if(wp.startsWith("<"))
  {
      wp =  wp.substring(1, wp.length()-1);
  }
     
     model.passengerAtCentral((int) temp.intValue(null), wp);
     
      return new VoidValue();
    }
    
    public Value passengerAnnoyed(Value id) throws ValueException{

     final Value temp = id;
     model.passengerAnnoyed((int) temp.intValue(null));
     
      return new VoidValue();
    }
    
    public Value passengerGotOnBus(Value id) throws ValueException{
 
  final Value temp = id;
     model.passengerGotOnBus((int) temp.intValue(null));
     
      return new VoidValue();
    }
    
    public Value inflowChanged(Value val) throws ValueException{
     
  final Value temp = val;
     model.inflowChanged((int) temp.intValue(null));
     
     return new VoidValue();
    }

 public Value busStopping(Value busline) throws ValueException {
  
  model.busArrived((int)busline.intValue(null));
  
  return new VoidValue();
 }
 
 public Value busAdded(Value busline) throws ValueException {
  
  model.busAdded((int)busline.intValue(null));
  
  return new VoidValue();
 }
 
 public Value busPassengerCountChanged(Value busline, Value count) throws ValueException {
  
  model.busPassengerCountChanged((int)busline.intValue(null), (int)count.intValue(null));
  
  return new VoidValue();
 }
}

¤ Dauer der Verarbeitung: 0.18 Sekunden  (vorverarbeitet)  ¤





Druckansicht
unsichere Verbindung
Druckansicht
sprechenden Kalenders

in der Quellcodebibliothek suchen




schauen Sie vor die Tür

Fenster


Die Firma ist wie angegeben erreichbar.

Die farbliche Syntaxdarstellung ist noch experimentell.


Bot Zugriff



                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik