package kz.cafe.db.model;

import java.util.*;
import kz.cafe.constants.*;
import kz.cafe.constants.InterfaceConstants.LANGS;
import kz.cafe.db.model.anotations.*;

public abstract class MAbstractDescriptor extends MAbstractEditableDataElement{
   private static final long serialVersionUID = -4728140722225400112L;


   @AnnotationNotExported
   public static final String F_IMAGE = "image"; 
   
   
   @AnnotationMultiLangString   
   @AnnotationNoExportIndex
   public Map<InterfaceConstants.LANGS, String> name = new HashMap<LANGS, String>();
   
   @AnnotationMultiLangString
   @AnnotationNotExported
   public Map<InterfaceConstants.LANGS, String> name_ = new HashMap<LANGS, String>();
   
   
   @AnnotationMultiLangString   
   @AnnotationNoExportIndex
   public Map<InterfaceConstants.LANGS, String> description = new HashMap<LANGS, String>();
   
   @AnnotationMultiLangString
   @AnnotationNotExported
   public Map<InterfaceConstants.LANGS, String> description_ = new HashMap<LANGS, String>();
   

   @AnnotationImage
   public String image = InterfaceConstants.EMPTY_IMAGE;

   
   public int order;
   
   
   @Override
   public String humanReadable(InterfaceConstants.LANGS lang){
//      return name.get(lang) + " [" + ID + "]";
      return name.get(lang);
   }


   @Override
   public String toString(){
      return super.toString() + ", name=" + name + ", name_=" + name_ + ", description="
               + description + ", description_=" + description_ + ", image=" + image + ", order="
               + order;
   }
}
