Back to index

plone3  3.1.7
Public Member Functions | Static Public Attributes | Static Private Attributes
Archetypes.BaseFolder.BaseFolder Class Reference
Inheritance diagram for Archetypes.BaseFolder.BaseFolder:
Inheritance graph
[legend]
Collaboration diagram for Archetypes.BaseFolder.BaseFolder:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def __init__
def Description
def setDescription
def manage_afterAdd
def manage_afterClone
def manage_beforeDelete
def manage_delObjects
def listFolderContents
def folderlistingFolderContents
def Title
def setTitle
def __getitem__
def manage_addFolder
def MKCOL_handler
def manage_afterMKCOL

Static Public Attributes

 schema = BaseFolderMixin.schema+ExtensibleMetadata.schema
tuple security = ClassSecurityInfo()
 manage_options = PortalFolder.manage_options
string content_icon = "folder_icon.gif"
int use_folder_tabs = 1
int isPrincipiaFolderish = 1
int isAnObjectManager = 1
 index_html = None
 PUT = WebDAVSupport.PUT
 manage_FTPget = WebDAVSupport.manage_FTPget
 manage_afterPUT = WebDAVSupport.manage_afterPUT

Static Private Attributes

 __implements__ = BaseFolderMixin.__implements__,IExtensibleMetadata

Detailed Description

A not-so-basic Folder implementation, with Dublin Core
Metadata included

Definition at line 232 of file BaseFolder.py.


Constructor & Destructor Documentation

def Archetypes.BaseFolder.BaseFolder.__init__ (   self,
  oid,
  kwargs 
)

Reimplemented from Archetypes.BaseFolder.BaseFolderMixin.

Definition at line 243 of file BaseFolder.py.

00243 
00244     def __init__(self, oid, **kwargs):
00245         # Call skinned first cause baseobject will set new defaults on
00246         # those attributes anyway
00247         BaseFolderMixin.__init__(self, oid, **kwargs)
00248         ExtensibleMetadata.__init__(self)

Here is the caller graph for this function:


Member Function Documentation

def Archetypes.BaseFolder.BaseFolderMixin.__getitem__ (   self,
  key 
) [inherited]
Overwrite __getitem__.

At first it's using the BaseObject version. If the element can't be
retrieved from the schema it's using PortalFolder as fallback which
should be the ObjectManager's version.

Definition at line 152 of file BaseFolder.py.

00152 
00153     def __getitem__(self, key):
00154         """Overwrite __getitem__.
00155 
00156         At first it's using the BaseObject version. If the element can't be
00157         retrieved from the schema it's using PortalFolder as fallback which
00158         should be the ObjectManager's version.
00159         """
00160         try:
00161             return BaseObject.__getitem__(self, key)
00162         except KeyError:
00163             return PortalFolder.__getitem__(self, key)

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolder.Description (   self,
  kwargs 
)
We have to override Description here to handle arbitrary
arguments since PortalFolder defines it.

Definition at line 251 of file BaseFolder.py.

00251 
00252     def Description(self, **kwargs):
00253         """We have to override Description here to handle arbitrary
00254         arguments since PortalFolder defines it."""
00255         return self.getField('description').get(self, **kwargs)

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.folderlistingFolderContents (   self,
  contentFilter = None,
  suppressHiddenFiles = 0 
) [inherited]
Calls listFolderContents in protected only by ACI so that
folder_listing can work without the List folder contents permission,
as in CMFDefault.

Definition at line 131 of file BaseFolder.py.

00131 
00132                                     suppressHiddenFiles=0):
00133         """Calls listFolderContents in protected only by ACI so that
00134         folder_listing can work without the List folder contents permission,
00135         as in CMFDefault.
00136         """
00137         return self.listFolderContents(contentFilter=contentFilter,
00138                                        suppressHiddenFiles=suppressHiddenFiles)

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.listFolderContents (   self,
  contentFilter = None,
  suppressHiddenFiles = 0 
) [inherited]
Optionally you can suppress "hidden" files, or files that begin
with a dot.

Definition at line 118 of file BaseFolder.py.

00118 
00119     def listFolderContents(self, contentFilter=None, suppressHiddenFiles=0):
00120         """Optionally you can suppress "hidden" files, or files that begin
00121         with a dot.
00122         """
00123         contents=PortalFolder.listFolderContents(self, contentFilter=contentFilter)
00124         if suppressHiddenFiles:
00125             contents=[obj for obj in contents if obj.getId()[:1]!='.']
00126 
00127         return contents

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.manage_addFolder (   self,
  id,
  title = '',
  REQUEST = None,
  type_name = None 
) [inherited]
Add a new folder-like object with id *id*.

IF present, use the parent object's 'mkdir' alias; otherwise, just add
a PortalFolder.

Definition at line 173 of file BaseFolder.py.

00173 
00174                          type_name=None):
00175         """Add a new folder-like object with id *id*.
00176 
00177         IF present, use the parent object's 'mkdir' alias; otherwise, just add
00178         a PortalFolder.
00179         """
00180         ti = self.getTypeInfo()
00181         # BBB getMethodURL is part of CMF 1.5 but AT 1.3 should be compatible
00182         # with CMF 1.4
00183         try:
00184             method = ti and ti.getMethodURL('mkdir') or None
00185         except AttributeError:
00186             method = None
00187         if method is not None:
00188             # call it
00189             getattr(self, method)(id=id)
00190         else:
00191             if type_name is None:
00192                 type_name = getattr(self, '_at_type_subfolder', None)
00193             if type_name is None:
00194                 type_name = ti and ti.getId() or 'Folder'
00195             self.invokeFactory(type_name, id=id)
00196 
00197         ob = self._getOb(id)
00198         try:
00199             ob.setTitle(title)
00200         except AttributeError:
00201             pass
00202         try:
00203             ob.reindexObject()
00204         except AttributeError:
00205             pass

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.manage_afterAdd (   self,
  item,
  container 
) [inherited]

Definition at line 90 of file BaseFolder.py.

00090 
00091     def manage_afterAdd(self, item, container):
00092         BaseObject.manage_afterAdd(self, item, container)

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.manage_afterClone (   self,
  item 
) [inherited]

Definition at line 94 of file BaseFolder.py.

00094 
00095     def manage_afterClone(self, item):
00096         BaseObject.manage_afterClone(self, item)

def Archetypes.BaseFolder.BaseFolderMixin.manage_afterMKCOL (   self,
  id,
  result,
  REQUEST = None,
  RESPONSE = None 
) [inherited]
After MKCOL handler.

Definition at line 215 of file BaseFolder.py.

00215 
00216     def manage_afterMKCOL(self, id, result, REQUEST=None, RESPONSE=None):
00217         """After MKCOL handler.
00218         """
00219         pass

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.manage_beforeDelete (   self,
  item,
  container 
) [inherited]

Definition at line 98 of file BaseFolder.py.

00098 
00099     def manage_beforeDelete(self, item, container):
00100         BaseObject.manage_beforeDelete(self, item, container)
00101         #and reset the rename flag (set in Referenceable._notifyCopyOfCopyTo)
00102         self._v_cp_refs = None

def Archetypes.BaseFolder.BaseFolderMixin.manage_delObjects (   self,
  ids = [],
  REQUEST = None 
) [inherited]
We need to enforce security.

Definition at line 105 of file BaseFolder.py.

00105 
00106     def manage_delObjects(self, ids=[], REQUEST=None):
00107         """We need to enforce security."""
00108         if isinstance(ids, basestring):
00109             ids = [ids]
00110         for id in ids:
00111             item = self._getOb(id)
00112             if not _checkPermission(permissions.DeleteObjects, item):
00113                 raise Unauthorized, (
00114                     "Do not have permissions to remove this object")
00115         return PortalFolder.manage_delObjects(self, ids, REQUEST=REQUEST)

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.MKCOL_handler (   self,
  id,
  REQUEST = None,
  RESPONSE = None 
) [inherited]
Hook into the MKCOL (make collection) process to call
manage_afterMKCOL.

Definition at line 206 of file BaseFolder.py.

00206 
00207     def MKCOL_handler(self, id, REQUEST=None, RESPONSE=None):
00208         """Hook into the MKCOL (make collection) process to call
00209         manage_afterMKCOL.
00210         """
00211         result = PortalFolder.MKCOL_handler(self, id, REQUEST, RESPONSE)
00212         self.manage_afterMKCOL(id, result, REQUEST, RESPONSE)
00213         return result

Here is the call graph for this function:

def Archetypes.BaseFolder.BaseFolder.setDescription (   self,
  value,
  kwargs 
)
We have to override setDescription here to handle arbitrary
arguments since PortalFolder defines it.

Definition at line 258 of file BaseFolder.py.

00258 
00259     def setDescription(self, value, **kwargs):
00260         """We have to override setDescription here to handle arbitrary
00261         arguments since PortalFolder defines it."""
00262         self.getField('description').set(self, value, **kwargs)
00263 
00264 InitializeClass(BaseFolder)

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.setTitle (   self,
  value,
  kwargs 
) [inherited]
We have to override setTitle here to handle arbitrary
arguments since PortalFolder defines it.

Definition at line 147 of file BaseFolder.py.

00147 
00148     def setTitle(self, value, **kwargs):
00149         """We have to override setTitle here to handle arbitrary
00150         arguments since PortalFolder defines it."""
00151         self.getField('title').set(self, value, **kwargs)

Here is the call graph for this function:

Here is the caller graph for this function:

def Archetypes.BaseFolder.BaseFolderMixin.Title (   self,
  kwargs 
) [inherited]
We have to override Title here to handle arbitrary arguments since
PortalFolder defines it.

Definition at line 140 of file BaseFolder.py.

00140 
00141     def Title(self, **kwargs):
00142         """We have to override Title here to handle arbitrary arguments since
00143         PortalFolder defines it."""
00144         return self.getField('title').get(self, **kwargs)

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Reimplemented from Archetypes.BaseFolder.BaseFolderMixin.

Definition at line 236 of file BaseFolder.py.

string Archetypes.BaseFolder.BaseFolderMixin.content_icon = "folder_icon.gif" [static, inherited]

Definition at line 45 of file BaseFolder.py.

Definition at line 55 of file BaseFolder.py.

Definition at line 48 of file BaseFolder.py.

Definition at line 47 of file BaseFolder.py.

Definition at line 227 of file BaseFolder.py.

Definition at line 224 of file BaseFolder.py.

Archetypes.BaseFolder.BaseFolderMixin.manage_options = PortalFolder.manage_options [static, inherited]

Definition at line 44 of file BaseFolder.py.

Definition at line 221 of file BaseFolder.py.

Archetypes.BaseFolder.BaseFolder.schema = BaseFolderMixin.schema+ExtensibleMetadata.schema [static]

Definition at line 239 of file BaseFolder.py.

tuple Archetypes.BaseFolder.BaseFolder.security = ClassSecurityInfo() [static]

Reimplemented from Archetypes.BaseFolder.BaseFolderMixin.

Definition at line 241 of file BaseFolder.py.

Definition at line 46 of file BaseFolder.py.


The documentation for this class was generated from the following file: