vtm/quelldatein/aufbau/schreiber.ts
Christian Fraß 9d603364b1 sicherung
2017-11-08 15:05:06 +01:00

67 lines
1.1 KiB
TypeScript

module mod_vtm_aufbau
{
/**
* @author kcf <vidofnir@folksprak.org>
*/
export class klasse_schreiber
implements schnittstelle_aktor
{
/**
* @author kcf <vidofnir@folksprak.org>
*/
private richtung : typ_richtung;
/**
* @author kcf <vidofnir@folksprak.org>
*/
private symbol : typ_symbol;
/**
* @author kcf <vidofnir@folksprak.org>
*/
public constructor(richtung : typ_richtung = 0, symbol : typ_symbol = 0)
{
this.richtung = richtung;
this.symbol = symbol;
}
/**
* @author kcf <vidofnir@folksprak.org>
*/
public richtung_lesen() : typ_richtung
{
return this.richtung;
}
/**
* @author kcf <vidofnir@folksprak.org>
*/
public symbol_lesen() : typ_symbol
{
return this.symbol;
}
/**
* @author kcf <vidofnir@folksprak.org>
* @implementation
*/
public verwenden(figur : klasse_figur) : void
{
figur.band_schreiben(this.symbol);
figur.bewegen(this.richtung);
}
}
}