Skip to content

Commit

Permalink
update the API definitions
Browse files Browse the repository at this point in the history
  • Loading branch information
janwijbrand committed May 1, 2012
1 parent 9120d6b commit 0de7af8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/grokcore/site/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#
##############################################################################


from zope.site.hooks import getSite
from grokcore.component import *
from grokcore.site.directive import site, local_utility
from grokcore.site.components import Site, LocalUtility, Application
Expand Down
7 changes: 7 additions & 0 deletions src/grokcore/site/interfaces.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ def __call__(site, utility, provides, name=u'',

class IBaseClasses(Interface):
Site = Attribute("Mixin class for sites.")

LocalUtility = Attribute("Base class for local utilities.")

Application = Attribute("Base class for applications.")


Expand Down Expand Up @@ -82,5 +84,10 @@ def provides(interface):
class IGrokcoreSiteAPI(IGrokcoreComponentAPI, IBaseClasses, IDirectives):
"""grokcore.site's public API."""

IApplication = Attribute('The application model interface')

def getSite():
"""Get the current site."""

def getApplication():
"""Return the nearest enclosing `grok.Application`."""

0 comments on commit 0de7af8

Please sign in to comment.