/*************************************************************/
/* Copyright (c) 2013 by progress Software Corporation       */
/*                                                           */
/* all rights reserved.  no part of this program or document */
/* may be  reproduced in  any form  or by  any means without */
/* permission in writing from progress Software Corporation. */
/*************************************************************/
/*------------------------------------------------------------------------
    Purpose     : interface for partition owner (tenant, tenant group or partition policy detail)
    Syntax      : 
    Description : 
    Author(s)   : hdaniels
    Created     : Feb 2013
    Notes       : Not mapped directly to any data source  
                  Sub interfaces 
                     - ITenant
                     - ITenantGroup  
                     - IPartitionPolicyDetail 
  ----------------------------------------------------------------------*/
 
using OpenEdge.DataAdmin.IDataAdminElement from propath.
 
using OpenEdge.DataAdmin.IPartitionMap from propath.
using OpenEdge.DataAdmin.IPartitionParent from propath.
 
interface OpenEdge.DataAdmin.IPartitionOwner inherits IPartitionParent :  
      
    /** Id internal unique integer identifier - read-only - generated by database 
        (internal - dump and load will generate a new id) */    
    define public property Id as int no-undo                   get.
    
    /** Partitions IPartitionMap property with all partitions of the tenant
        mapped by ISchemaElement (ITable,IIndex,IField)     */                    
    define public property Partitions      as IPartitionMap no-undo get.
     
     /** IsDataEnabled 
          default true gives access to partitioned data 
          set to false to prevent access to partitioned data 
          (only shared data accessible)  */    
    define public property IsDataEnabled as logical no-undo         get. set. 
     
    /** IsAllocated 
          <b>true</b> if all partitions have a state of Allocated or None
          false if any partition have a state of Delayed 
          Use Allocate() to allocate delayed partitions
          Owners that has a single table and does not support delayed partitions implements this 
          as directly exposing if it has allocated partitions. (all partitions are allocated in synch for a table)  */
              
    define public property IsAllocated as logical no-undo      get.
    
    /** Allocates the owner's partitions   -   (the parent must be passed to a service
    update or create method to commit the changes)  */                    
    method public logical Allocate().
end interface.