JavaFX/model/LangModel.java

39 lines
626 B
Java
Raw Normal View History

package model;
import Classes.Languages;
public class LangModel {
2017-11-19 15:30:22 +00:00
private static LangModel instance;
2017-11-19 15:30:22 +00:00
private Languages fromLang = Languages.fr;
2017-11-19 15:30:22 +00:00
private Languages toLang = Languages.en;
private LangModel(){}
public static LangModel getInstance(){
if( LangModel.instance == null )
LangModel.instance = new LangModel();
2017-11-19 15:30:22 +00:00
return LangModel.instance;
}
2017-11-19 15:30:22 +00:00
public void setFromLang(Languages lang){
this.fromLang = lang;
}
2017-11-19 15:30:22 +00:00
public Languages getFromLang(){
return this.fromLang;
}
2017-11-19 15:30:22 +00:00
public void setToLang(Languages lang){
this.toLang = lang;
}
2017-11-19 15:30:22 +00:00
public Languages getToLang(){
return this.toLang;
}
}