# 类分层结构
Date: 2020-05-30

# 所有程序包的分层结构

程序包分层结构:

- com.java2nb.novel,
- com.java2nb.novel.author.entity,
- com.java2nb.novel.author.mapper,
- com.java2nb.novel.book.api,
- com.java2nb.novel.book.controller,
- com.java2nb.novel.book.controller.api,
- com.java2nb.novel.book.entity,
- com.java2nb.novel.book.feign,
- com.java2nb.novel.book.mapper,
- com.java2nb.novel.book.service,
- com.java2nb.novel.book.service.impl,
- com.java2nb.novel.book.vo,
- com.java2nb.novel.common.base,
- com.java2nb.novel.common.bean,
- com.java2nb.novel.common.cache,
- com.java2nb.novel.common.cache.impl,
- com.java2nb.novel.common.config,
- com.java2nb.novel.common.enums,
- com.java2nb.novel.common.exception,
- com.java2nb.novel.common.utils,
- com.java2nb.novel.gateway,
- com.java2nb.novel.gateway.config,
- com.java2nb.novel.gen,
- com.java2nb.novel.home.controller,
- com.java2nb.novel.home.entity,
- com.java2nb.novel.home.feign,
- com.java2nb.novel.home.mapper,
- com.java2nb.novel.home.service,
- com.java2nb.novel.home.service.impl,
- com.java2nb.novel.home.vo,
- com.java2nb.novel.monitor,
- com.java2nb.novel.monitor.config,
- com.java2nb.novel.news.api,
- com.java2nb.novel.news.controller,
- com.java2nb.novel.news.controller.api,
- com.java2nb.novel.news.entity,
- com.java2nb.novel.news.mapper,
- com.java2nb.novel.news.service,
- com.java2nb.novel.news.service.impl,
- com.java2nb.novel.news.vo,
- com.java2nb.novel.pay.entity,
- com.java2nb.novel.pay.mapper,
- com.java2nb.novel.search.controller,
- com.java2nb.novel.search.feign,
- com.java2nb.novel.search.schedule,
- com.java2nb.novel.search.service,
- com.java2nb.novel.search.service.impl,
- com.java2nb.novel.search.vo,
- com.java2nb.novel.user.api,
- com.java2nb.novel.user.controller,
- com.java2nb.novel.user.controller.api,
- com.java2nb.novel.user.entity,
- com.java2nb.novel.user.feign,
- com.java2nb.novel.user.form,
- com.java2nb.novel.user.mapper,
- com.java2nb.novel.user.service,
- com.java2nb.novel.user.service.impl,
- com.java2nb.novel.user.vo

## 类分层结构

- java.lang.Object
  - com.java2nb.novel.author.entity.Author
  - com.java2nb.novel.author.entity.Author
  - com.java2nb.novel.AuthorApplication
  - com.java2nb.novel.author.entity.AuthorCode
  - com.java2nb.novel.author.entity.AuthorCode
  - com.java2nb.novel.author.mapper.AuthorCodeDynamicSqlSupport
  - com.java2nb.novel.author.mapper.AuthorCodeDynamicSqlSupport
  - com.java2nb.novel.author.mapper.AuthorCodeMapper
  - com.java2nb.novel.author.mapper.AuthorDynamicSqlSupport
  - com.java2nb.novel.author.mapper.AuthorDynamicSqlSupport
  - com.java2nb.novel.author.mapper.AuthorMapper
  - com.java2nb.novel.common.base.BaseController
    - com.java2nb.novel.user.controller.UserController
  - com.java2nb.novel.common.utils.BeanUtil
  - com.java2nb.novel.book.entity.Book
    - com.java2nb.novel.book.vo.BookVO
  - com.java2nb.novel.book.entity.Book
  - com.java2nb.novel.book.controller.api.BookApi
  - com.java2nb.novel.BookApplication
  - com.java2nb.novel.book.entity.BookCategory
  - com.java2nb.novel.book.entity.BookCategory
  - com.java2nb.novel.book.mapper.BookCategoryDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookCategoryDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookCategoryMapper
  - com.java2nb.novel.book.entity.BookComment
    - com.java2nb.novel.book.vo.BookCommentVO
  - com.java2nb.novel.book.entity.BookComment
  - com.java2nb.novel.book.mapper.BookCommentDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookCommentDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookCommentMapper
  - com.java2nb.novel.book.entity.BookCommentReply
  - com.java2nb.novel.book.entity.BookCommentReply
  - com.java2nb.novel.book.mapper.BookCommentReplyDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookCommentReplyDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookCommentReplyMapper
  - com.java2nb.novel.book.entity.BookContent
  - com.java2nb.novel.book.entity.BookContent
  - com.java2nb.novel.book.mapper.BookContentDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookContentDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookContentMapper
  - com.java2nb.novel.book.controller.BookController
  - com.java2nb.novel.book.mapper.BookDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookDynamicSqlSupport
  - com.java2nb.novel.book.entity.BookIndex
  - com.java2nb.novel.book.entity.BookIndex
  - com.java2nb.novel.book.mapper.BookIndexDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookIndexDynamicSqlSupport
  - com.java2nb.novel.book.mapper.BookIndexMapper
  - com.java2nb.novel.book.mapper.BookMapper
  - com.java2nb.novel.book.service.impl.BookServiceImpl (implements com.java2nb.novel.book.service.BookService)
  - com.java2nb.novel.search.schedule.BookToEsSchedule
  - com.java2nb.novel.common.exception.CommonExceptionHandler
  - com.java2nb.novel.common.utils.Constants
  - com.java2nb.novel.common.utils.CookieUtil
  - org.mybatis.generator.internal.DefaultCommentGenerator (implements org.mybatis.generator.api.CommentGenerator)
    - com.java2nb.novel.gen.CommentGenerator
  - com.java2nb.novel.search.vo.EsBookVO
  - com.java2nb.novel.common.utils.FileUtil
  - com.java2nb.novel.gateway.GatewayApplication
  - com.java2nb.novel.gen.Generator
  - com.java2nb.novel.HomeApplication
  - com.java2nb.novel.home.entity.HomeBook
    - com.java2nb.novel.home.vo.HomeBookVO (implements java.io.Serializable)
  - com.java2nb.novel.home.entity.HomeBook
  - com.java2nb.novel.home.mapper.HomeBookDynamicSqlSupport
  - com.java2nb.novel.home.mapper.HomeBookDynamicSqlSupport
  - com.java2nb.novel.home.mapper.HomeBookMapper
  - com.java2nb.novel.home.controller.HomeController
  - com.java2nb.novel.home.entity.HomeFriendLink
  - com.java2nb.novel.home.entity.HomeFriendLink
  - com.java2nb.novel.home.mapper.HomeFriendLinkDynamicSqlSupport
  - com.java2nb.novel.home.mapper.HomeFriendLinkDynamicSqlSupport
  - com.java2nb.novel.home.mapper.HomeFriendLinkMapper
  - com.java2nb.novel.home.service.impl.HomeServiceImpl (implements com.java2nb.novel.home.service.HomeService)
  - com.java2nb.novel.common.utils.HttpUtil
  - com.java2nb.novel.common.utils.IdWorker
  - com.java2nb.novel.common.utils.IpUtil
  - com.java2nb.novel.common.utils.JwtTokenUtil
  - com.java2nb.novel.common.utils.MD5Util
  - com.java2nb.novel.news.entity.News
    - com.java2nb.novel.news.vo.NewsVO
  - com.java2nb.novel.news.entity.News
  - com.java2nb.novel.news.controller.api.NewsApi
  - com.java2nb.novel.NewsApplication
  - com.java2nb.novel.news.entity.NewsCategory
  - com.java2nb.novel.news.entity.NewsCategory
  - com.java2nb.novel.news.mapper.NewsCategoryDynamicSqlSupport
  - com.java2nb.novel.news.mapper.NewsCategoryDynamicSqlSupport
  - com.java2nb.novel.news.mapper.NewsCategoryMapper
  - com.java2nb.novel.news.controller.NewsController
  - com.java2nb.novel.news.mapper.NewsDynamicSqlSupport
  - com.java2nb.novel.news.mapper.NewsDynamicSqlSupport
  - com.java2nb.novel.news.mapper.NewsMapper
  - com.java2nb.novel.news.service.impl.NewsServiceImpl (implements com.java2nb.novel.news.service.NewsService)
  - com.java2nb.novel.gateway.config.NovelCorsConfig
  - com.java2nb.novel.monitor.NovelMonitorApplication
  - com.java2nb.novel.common.bean.PageBean<T>
  - com.java2nb.novel.PayApplication
  - com.java2nb.novel.pay.entity.PayLog
  - com.java2nb.novel.pay.entity.PayLog
  - com.java2nb.novel.pay.mapper.PayLogDynamicSqlSupport
  - com.java2nb.novel.pay.mapper.PayLogDynamicSqlSupport
  - com.java2nb.novel.pay.mapper.PayLogMapper
  - com.java2nb.novel.common.utils.RandomBookInfoUtil
  - com.java2nb.novel.common.utils.RandomValidateCodeUtil
  - com.java2nb.novel.common.cache.impl.RedisServiceImpl (implements com.java2nb.novel.common.cache.CacheService)
  - com.java2nb.novel.common.utils.RestTemplateUtil
  - com.java2nb.novel.common.bean.ResultBean<T>
  - com.java2nb.novel.SearchApplication
  - com.java2nb.novel.search.controller.SearchController
  - com.java2nb.novel.search.vo.SearchParamVO
  - com.java2nb.novel.search.service.impl.SearchServiceImpl (implements com.java2nb.novel.search.service.SearchService)
  - com.java2nb.novel.common.utils.SpringUtil (implements org.springframework.context.ApplicationContextAware)
  - org.mybatis.dynamic.sql.SqlTable
    - com.java2nb.novel.author.mapper.AuthorCodeDynamicSqlSupport.AuthorCode
    - com.java2nb.novel.author.mapper.AuthorDynamicSqlSupport.Author
    - com.java2nb.novel.book.mapper.BookCategoryDynamicSqlSupport.BookCategory
    - com.java2nb.novel.book.mapper.BookCommentDynamicSqlSupport.BookComment
    - com.java2nb.novel.book.mapper.BookCommentReplyDynamicSqlSupport.BookCommentReply
    - com.java2nb.novel.book.mapper.BookContentDynamicSqlSupport.BookContent
    - com.java2nb.novel.book.mapper.BookDynamicSqlSupport.Book
    - com.java2nb.novel.book.mapper.BookIndexDynamicSqlSupport.BookIndex
    - com.java2nb.novel.home.mapper.HomeBookDynamicSqlSupport.HomeBook
    - com.java2nb.novel.home.mapper.HomeFriendLinkDynamicSqlSupport.HomeFriendLink
    - com.java2nb.novel.news.mapper.NewsCategoryDynamicSqlSupport.NewsCategory
    - com.java2nb.novel.news.mapper.NewsDynamicSqlSupport.News
    - com.java2nb.novel.pay.mapper.PayLogDynamicSqlSupport.PayLog
    - com.java2nb.novel.user.mapper.UserBookshelfDynamicSqlSupport.UserBookshelf
    - com.java2nb.novel.user.mapper.UserBuyRecordDynamicSqlSupport.UserBuyRecord
    - com.java2nb.novel.user.mapper.UserDynamicSqlSupport.User
    - com.java2nb.novel.user.mapper.UserFeedbackDynamicSqlSupport.UserFeedback
    - com.java2nb.novel.user.mapper.UserPayRecordDynamicSqlSupport.UserPayRecord
    - com.java2nb.novel.user.mapper.UserReadHistoryDynamicSqlSupport.UserReadHistory
  - com.java2nb.novel.common.utils.StringUtil
  - com.java2nb.novel.common.config.Swagger2Config
  - com.java2nb.novel.common.utils.ThreadUtil
  - java.lang.Throwable (implements java.io.Serializable)
    - java.lang.Exception
      - java.lang.RuntimeException
        - com.java2nb.novel.common.exception.BusinessException
  - com.java2nb.novel.user.entity.User (implements java.io.Serializable)
  - com.java2nb.novel.user.controller.api.UserApi
  - com.java2nb.novel.UserApplication
  - com.java2nb.novel.user.entity.UserBookshelf
    - com.java2nb.novel.user.vo.BookShelfVO
  - com.java2nb.novel.user.entity.UserBookshelf
  - com.java2nb.novel.user.mapper.UserBookshelfDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserBookshelfDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserBookshelfMapper
  - com.java2nb.novel.user.entity.UserBuyRecord
  - com.java2nb.novel.user.entity.UserBuyRecord
  - com.java2nb.novel.user.mapper.UserBuyRecordDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserBuyRecordDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserBuyRecordMapper
  - com.java2nb.novel.common.bean.UserDetails
  - com.java2nb.novel.user.mapper.UserDynamicSqlSupport
  - com.java2nb.novel.user.entity.UserFeedback
  - com.java2nb.novel.user.entity.UserFeedback
  - com.java2nb.novel.user.mapper.UserFeedbackDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserFeedbackDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserFeedbackMapper
  - com.java2nb.novel.user.form.UserForm
  - com.java2nb.novel.user.entity.UserPayRecord
  - com.java2nb.novel.user.entity.UserPayRecord
  - com.java2nb.novel.user.mapper.UserPayRecordDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserPayRecordDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserPayRecordMapper
  - com.java2nb.novel.user.entity.UserReadHistory
    - com.java2nb.novel.user.vo.BookReadHistoryVO
  - com.java2nb.novel.user.entity.UserReadHistory
  - com.java2nb.novel.user.mapper.UserReadHistoryDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserReadHistoryDynamicSqlSupport
  - com.java2nb.novel.user.mapper.UserReadHistoryMapper
  - com.java2nb.novel.user.service.impl.UserServiceImpl (implements com.java2nb.novel.user.service.UserService)
  - com.java2nb.novel.common.utils.UUIDUtil
  - org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter (implements org.springframework.security.config.annotation.web.WebSecurityConfigurer<T>)
    - com.java2nb.novel.monitor.config.SecuritySecureConfig

## 接口分层结构

- com.java2nb.novel.author.mapper.AuthorCodeMapper
- com.java2nb.novel.author.mapper.AuthorMapper
- com.java2nb.novel.book.api.BookApi
  - com.java2nb.novel.home.feign.BookFeignClient
  - com.java2nb.novel.search.feign.BookFeignClient
  - com.java2nb.novel.user.feign.BookFeignClient
- com.java2nb.novel.book.mapper.BookCategoryMapper
- com.java2nb.novel.book.mapper.BookCommentMapper
- com.java2nb.novel.book.mapper.BookCommentReplyMapper
- com.java2nb.novel.book.mapper.BookContentMapper
- com.java2nb.novel.book.mapper.BookIndexMapper
- com.java2nb.novel.book.mapper.BookMapper
- com.java2nb.novel.book.service.BookService
- com.java2nb.novel.common.cache.CacheKey
- com.java2nb.novel.common.cache.CacheService
- com.java2nb.novel.home.mapper.HomeBookMapper
- com.java2nb.novel.home.mapper.HomeFriendLinkMapper
- com.java2nb.novel.home.service.HomeService
- com.java2nb.novel.news.api.NewsApi
  - com.java2nb.novel.home.feign.NewsFeignClient
- com.java2nb.novel.news.mapper.NewsCategoryMapper
- com.java2nb.novel.news.mapper.NewsMapper
- com.java2nb.novel.news.service.NewsService
- com.java2nb.novel.pay.mapper.PayLogMapper
- com.java2nb.novel.search.service.SearchService
- com.java2nb.novel.user.api.UserApi
  - com.java2nb.novel.book.feign.UserFeignClient
- com.java2nb.novel.user.mapper.UserBookshelfMapper
- com.java2nb.novel.user.mapper.UserBuyRecordMapper
- com.java2nb.novel.user.mapper.UserFeedbackMapper
- com.java2nb.novel.user.mapper.UserMapper
- com.java2nb.novel.user.mapper.UserPayRecordMapper
- com.java2nb.novel.user.mapper.UserReadHistoryMapper
- com.java2nb.novel.user.service.UserService

## 枚举分层结构

- java.lang.Object
  - java.lang.Enum<E> (implements java.lang.Comparable<T>, java.io.Serializable)
    - com.java2nb.novel.common.enums.ResponseStatus