implement some specials methods in domain class