SimplePersonalLibrary.java 文件源码

java
阅读 16 收藏 0 点赞 0 评论 0

项目:cacheonix-core 作者:
public SimplePersonalLibrary(String relationTypeName)
{
   super(relationTypeName);

   try
   {
      RoleInfo ownerRoleInfo = new RoleInfo("owner",
                                            // the name of the MBean class of which all members must be an instance.
                                            "mx4j.examples.services.relation.SimpleOwner",
                                            true, //read
                                            true, //write
                                            1, // only one owner
                                            1,
                                            "Owner");
      addRoleInfo(ownerRoleInfo);

      RoleInfo booksRoleInfo = new RoleInfo("books",
                                            "mx4j.examples.services.relation.SimpleBooks",
                                            true,
                                            true,
                                            1, // feeling nasty can only own max 4 books and no fewer than 1
                                            4,
                                            "Books");
      addRoleInfo(booksRoleInfo);
   }
   catch (Exception ex)
   {
      throw new RuntimeException(ex.getMessage());
   }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号