# -*- coding: utf-8 -*-

@@ -17,8 +17,2137 @@
 f-8 -*-%0A
+%0Aimport random%0Aimport yaml%0A%0A%0Aclass Prefecture(object):%0A    def __init__(self):%0A        from gimei import Gimei%0A        self.prefectures = random.choice(Gimei.ADDRESSES%5B'addresses'%5D%5B'prefecture'%5D)%0A%0A    @property%0A    def kanji(self):%0A        return u%22%7B%7D%22.format(%0A            self.prefectures%5B0%5D%0A        )%0A%0A    @property%0A    def hiragana(self):%0A        return u%22%7B%7D%22.format(%0A            self.prefectures%5B1%5D%0A        )%0A%0A    @property%0A    def katakana(self):%0A        return u%22%7B%7D%22.format(%0A            self.prefectures%5B2%5D%0A        )%0A%0A%0Aclass City(object):%0A    def __init__(self):%0A        from gimei import Gimei%0A        self.cities = random.choice(Gimei.ADDRESSES%5B'addresses'%5D%5B'city'%5D)%0A%0A    @property%0A    def kanji(self):%0A        return u%22%7B%7D%22.format(%0A            self.cities%5B0%5D%0A        )%0A%0A    @property%0A    def hiragana(self):%0A        return u%22%7B%7D%22.format(%0A            self.cities%5B1%5D%0A        )%0A%0A    @property%0A    def katakana(self):%0A        return u%22%7B%7D%22.format(%0A            self.cities%5B2%5D%0A        )%0A%0A%0Aclass Town(object):%0A    def __init__(self):%0A        from gimei import Gimei%0A        self.towns = random.choice(Gimei.ADDRESSES%5B'addresses'%5D%5B'town'%5D)%0A%0A    @property%0A    def kanji(self):%0A        return u%22%7B%7D%22.format(%0A            self.towns%5B0%5D%0A        )%0A%0A    @property%0A    def hiragana(self):%0A        return u%22%7B%7D%22.format(%0A            self.towns%5B1%5D%0A        )%0A%0A    @property%0A    def katakana(self):%0A        return u%22%7B%7D%22.format(%0A            self.towns%5B2%5D%0A        )%0A%0A%0Aclass Address(object):%0A    def __init__(self):%0A        self.prefecture = Prefecture()%0A        self.city = City()%0A        self.town = Town()%0A%0A    @property%0A    def kanji(self):%0A        return u%22%7B%7D%7B%7D%7B%7D%22.format(%0A            self.prefecture.kanji,%0A            self.city.kanji,%0A            self.town.kanji,%0A        )%0A%0A    @property%0A    def hiragana(self):%0A        return u%22%7B%7D%7B%7D%7B%7D%22.format(%0A            self.prefecture.hiragana,%0A            self.city.hiragana,%0A            self.town.hiragana,%0A        )%0A%0A    @property%0A    def katakana(self):%0A        return u%22%7B%7D%7B%7D%7B%7D%22.format(%0A            self.prefecture.katakana,%0A            self.city.katakana,%0A            self.town.katakana,%0A        )%0A

Create Address class.