package pt.ist.bennu.core.domain; /* * @(#)domain_model.dml * * Copyright 2009 Instituto Superior Tecnico * Founding Authors: João Figueiredo, Luis Cruz, Paulo Abrantes, Susana Fernandes * * https://fenix-ashes.ist.utl.pt/ * * This file is part of the MyOrg web application infrastructure. * * MyOrg is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation, either version 3 of the License, or * (at your option) any later version.* * * MyOrg is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with MyOrg. If not, see . * */ enum pt.ist.bennu.core.domain.RoleType as RoleType; enum pt.ist.bennu.core.domain.ThemeType as ThemeType; valueType pt.ist.bennu.core.domain.util.Money as Money { externalizeWith { String exportAsString(); } internalizeWith importFromString(); } valueType pt.utl.ist.fenix.tools.util.i18n.MultiLanguageString as MultiLanguageString { externalizeWith { String exportAsString(); } internalizeWith importFromString(); } valueType org.joda.time.Interval as Interval { externalizeWith { String pt.ist.bennu.core.util.IntervalTools.intervalSerialize(); } internalizeWith pt.ist.bennu.core.util.IntervalTools.intervalDeserialize(); } valueType pt.utl.ist.fenix.tools.util.Strings as Strings { externalizeWith { String exportAsString(); } internalizeWith importFromString(); } valueType pt.utl.ist.fenix.tools.util.ByteArray as ByteArray { externalizeWith { bytearray getBytes(); } } valueType java.lang.Class as Class { externalizeWith { String getName(); } internalizeWith pt.ist.bennu.core.domain.util.ClassInternalizer.internalize(); } class MyOrg { } class contents.Node { Integer nodeOrder; } class contents.ActionNode extends contents.Node { String path; String method; String linkBundle; String linkKey; } class contents.LinkNode extends contents.Node { String url; String linkBundle; String linkKey; } class groups.PersistentGroup { } class groups.EmptyGroup extends groups.PersistentGroup { } class groups.AnonymousGroup extends groups.PersistentGroup { } class groups.AnyoneGroup extends groups.PersistentGroup { } class groups.UserGroup extends groups.PersistentGroup { } class groups.SingleUserGroup extends groups.PersistentGroup { } class groups.People extends groups.PersistentGroup { } class groups.NamedGroup extends groups.People { String groupName; } class groups.Role extends groups.NamedGroup { } class groups.UnionGroup extends groups.PersistentGroup { } class groups.IntersectionGroup extends groups.PersistentGroup { } class groups.IntersectionNamedGroup extends groups.IntersectionGroup { String groupName; } class groups.NegationGroup extends groups.PersistentGroup { } class groups.PeopleUserLog { DateTime operationDate; String operation; String username; String groupName; String executor; } class User { String username (REQUIRED); String password; DateTime lastLogoutDateTime; String email; } class PasswordRecoveryRequest { DateTime requested; String verificationHash; DateTime consumed; } class VirtualHost { String hostname; Boolean googleSearchEnabled; Boolean languageSelectionEnabled; Boolean breadCrumbsEnabled; MultiLanguageString applicationTitle; MultiLanguageString htmlTitle; MultiLanguageString applicationSubTitle; MultiLanguageString applicationCopyright; String errorPage (REQUIRED); String helpLink; ByteArray logo; ByteArray favicon; String supportEmailAddress; String systemEmailAddress; String supportedLanguages; } class Theme { String name; String description; ThemeType type; String screenshotFileName; } class Layout { String name; } relation ThemeMyOrg { MyOrg playsRole myOrg; Theme playsRole themes { multiplicity *; } } relation VirtualHostTheme { VirtualHost playsRole virtualHosts { multiplicity *; } Theme playsRole theme; } relation LayoutMyOrg { MyOrg playsRole myOrg; Layout playsRole layout { multiplicity *; } } relation VirtualHostLayout { VirtualHost playsRole virtualHosts { multiplicity *; } Layout playsRole layout; } relation MyOrgUser { MyOrg playsRole myOrg; User playsRole user { multiplicity *; } } relation MyOrgVirtualHost { MyOrg playsRole myOrg { multiplicity 1..1; } VirtualHost playsRole virtualHosts { multiplicity *; } } relation MyOrgNode { MyOrg playsRole myOrg; contents.Node playsRole nodes { multiplicity *; } } relation VirtualHostTopLevelNode { VirtualHost playsRole virtualHost; contents.Node playsRole topLevelNodes { multiplicity *; } } relation NodeNode { contents.Node playsRole parentNode; contents.Node playsRole childNodes { multiplicity *; } } relation MyOrgPersistentGroup { MyOrg playsRole myOrg; groups.PersistentGroup playsRole persistentGroups { multiplicity *; } } relation MyOrgSystemGroup { MyOrg playsRole systemGroupMyOrg; groups.PersistentGroup playsRole systemGroups { multiplicity *; } } relation MyOrgUserGroup { User playsRole groupOwner; groups.PersistentGroup playsRole userGroups { multiplicity *; } } relation PersistentGroupUnionGroup { groups.PersistentGroup playsRole persistentGroups { multiplicity *; } groups.UnionGroup playsRole unionGroups { multiplicity *; } } relation PersistentGroupIntersectionGroup { groups.PersistentGroup playsRole persistentGroups { multiplicity *; } groups.IntersectionGroup playsRole intersectionGroups { multiplicity *; } } relation PersistentGroupNegationGroup { groups.PersistentGroup playsRole persistentGroup; groups.NegationGroup playsRole negationGroups { multiplicity *; } } relation UserPeople { groups.People playsRole peopleGroups { multiplicity *; } User playsRole users { multiplicity *; } } relation NodePersistentGroup { contents.Node playsRole nodes { multiplicity *; } groups.PersistentGroup playsRole accessibilityGroup; } relation MyOrgPeopleUserLog { MyOrg playsRole myOrg; groups.PeopleUserLog playsRole peopleUserLog { multiplicity *; } } relation UserSingleUserGroup { groups.SingleUserGroup playsRole singleUserGroup; User playsRole user; } relation UserPasswordRecoveryRequest { User playsRole user; PasswordRecoveryRequest playsRole passwordRecoveryRequest; } relation PasswordRecoveryRequestPasswordRecoveryRequest { PasswordRecoveryRequest playsRole previous; PasswordRecoveryRequest playsRole next; }