Back to index

plone3  3.1.7
Public Member Functions
GenericSetup.interfaces.ISetupTool Class Reference
Inheritance diagram for GenericSetup.interfaces.ISetupTool:
Inheritance graph
[legend]
Collaboration diagram for GenericSetup.interfaces.ISetupTool:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def getEncoding
def getImportContextID
def getBaselineContextID
def setImportContext
def setBaselineContext
def applyContext
def getImportStepRegistry
def getExportStepRegistry
def getToolsetRegistry
def getProfileDependencyChain
def runImportStepFromProfile
def runImportStep
def runAllImportStepsFromProfile
def runAllImportSteps
def runExportStep
def runAllExportSteps
def createSnapshot
def compareConfigurations
def getProfileImportDate

Detailed Description

API for SetupTool.

Definition at line 442 of file interfaces.py.


Member Function Documentation

def GenericSetup.interfaces.ISetupTool.applyContext (   context,
  encoding = None 
)
Update the tool from the supplied context, without modifying its
    "permanent" ID.

Definition at line 478 of file interfaces.py.

00478 
00479     def applyContext( context, encoding=None ):
00480 
00481         """ Update the tool from the supplied context, without modifying its
00482             "permanent" ID.
00483         """

Here is the caller graph for this function:

def GenericSetup.interfaces.ISetupTool.compareConfigurations (   lhs_context,
  rhs_context,
  missing_as_empty = False,
  ignore_whitespace = False 
)
Compare two configurations.

o 'lhs_context' and 'rhs_context' must implement IImportContext.

o If 'missing_as_empty', then compare files not present as though
  they were zero-length;  otherwise, omit such files.

o If 'ignore_whitespace', then suppress diffs due only to whitespace
  (c.f:  'diff -wbB')

Definition at line 638 of file interfaces.py.

00638 
00639                              ):
00640         """ Compare two configurations.
00641 
00642         o 'lhs_context' and 'rhs_context' must implement IImportContext.
00643 
00644         o If 'missing_as_empty', then compare files not present as though
00645           they were zero-length;  otherwise, omit such files.
00646 
00647         o If 'ignore_whitespace', then suppress diffs due only to whitespace
00648           (c.f:  'diff -wbB')
00649         """

Here is the caller graph for this function:

Create a snapshot folder using all steps.

o 'snapshot_id' is the ID of the new folder.

Definition at line 627 of file interfaces.py.

00627 
00628     def createSnapshot( snapshot_id ):
00629 
00630         """ Create a snapshot folder using all steps.
00631 
00632         o 'snapshot_id' is the ID of the new folder.
00633         """

Here is the caller graph for this function:

Get the ID of the base profile for this configuration.

Definition at line 462 of file interfaces.py.

00462 
00463     def getBaselineContextID():
00464         """ Get the ID of the base profile for this configuration.
00465         """

Here is the caller graph for this function:

API for SetupTool.
Get the encoding used for configuration data within the site.

o Return None if the data should not be encoded.

Definition at line 447 of file interfaces.py.

00447 
00448     def getEncoding():
00449 
00450         """ Get the encoding used for configuration data within the site.
00451 
00452         o Return None if the data should not be encoded.
00453         """

Here is the caller graph for this function:

Return the IExportStepRegistry for the tool.

Definition at line 489 of file interfaces.py.

00489 
00490     def getExportStepRegistry():
00491 
00492         """ Return the IExportStepRegistry for the tool.
00493         """

Get the ID of the active import context.

DEPRECATED.  The idea of a stateful active import context is
going away.

Definition at line 454 of file interfaces.py.

00454 
00455     def getImportContextID():
00456 
00457         """ Get the ID of the active import context.
00458 
00459         DEPRECATED.  The idea of a stateful active import context is
00460         going away.
00461         """

Return the IImportStepRegistry for the tool.

Definition at line 484 of file interfaces.py.

00484 
00485     def getImportStepRegistry():
00486 
00487         """ Return the IImportStepRegistry for the tool.
00488         """

Return a list of dependencies for a profile.

The list is ordered by install order, with the requested profile as
last item.

Definition at line 499 of file interfaces.py.

00499 
00500     def getProfileDependencyChain( profile_id ):
00501 
00502         """Return a list of dependencies for a profile.
00503 
00504         The list is ordered by install order, with the requested profile as
00505         last item.
00506         """

Here is the caller graph for this function:

Return the last date an extension was imported.

o The result will be a string, formated as IS0.

Definition at line 650 of file interfaces.py.

00650 
00651     def getProfileImportDate(profile_id):
00652         """ Return the last date an extension was imported.
00653 
00654         o The result will be a string, formated as IS0.
00655         """
00656 

Return the IToolsetRegistry for the tool.

Definition at line 494 of file interfaces.py.

00494 
00495     def getToolsetRegistry():
00496 
00497         """ Return the IToolsetRegistry for the tool.
00498         """

Generate a tarball containing artifacts from all export steps.

o Return a mapping, with keys:

  'steps' -- a sequence of IDs of the steps run.

  'messages' -- a dictionary holding messages returned from each
    step

  'tarball' -- the stringified tar-gz data.

Definition at line 613 of file interfaces.py.

00613 
00614     def runAllExportSteps():
00615 
00616         """ Generate a tarball containing artifacts from all export steps.
00617 
00618         o Return a mapping, with keys:
00619 
00620           'steps' -- a sequence of IDs of the steps run.
00621 
00622           'messages' -- a dictionary holding messages returned from each
00623             step
00624 
00625           'tarball' -- the stringified tar-gz data.
00626         """

Here is the caller graph for this function:

Run all setup steps for the _import_context_id profile in
dependency order.

o If 'purge_old' is True, then run each step after purging any
  "old" setup first (this is the responsibility of the step,
  which must check the context we supply).

o Return a mapping, with keys:

  'steps' -- a sequence of IDs of the steps run.

  'messages' -- a dictionary holding messages returned from each
    step

DEPRECATED.  Use runAllImportStepsFromProfile instead.

Definition at line 578 of file interfaces.py.

00578 
00579     def runAllImportSteps(purge_old=None):
00580 
00581         """ Run all setup steps for the _import_context_id profile in
00582         dependency order.
00583 
00584         o If 'purge_old' is True, then run each step after purging any
00585           "old" setup first (this is the responsibility of the step,
00586           which must check the context we supply).
00587 
00588         o Return a mapping, with keys:
00589 
00590           'steps' -- a sequence of IDs of the steps run.
00591 
00592           'messages' -- a dictionary holding messages returned from each
00593             step
00594 
00595         DEPRECATED.  Use runAllImportStepsFromProfile instead.
00596         """

def GenericSetup.interfaces.ISetupTool.runAllImportStepsFromProfile (   profile_id,
  purge_old = None,
  ignore_dependencies = False 
)
Run all setup steps for the given profile in dependency order.

o 'profile_id' must be a valid ID of a registered profile;
   otherwise, raise KeyError.

o If 'purge_old' is True, then run each step after purging any
  "old" setup first (this is the responsibility of the step,
  which must check the context we supply).

o Unless 'ignore_dependencies' is true this will also import
  all profiles this profile depends on.

o Return a mapping, with keys:

  'steps' -- a sequence of IDs of the steps run.

  'messages' -- a dictionary holding messages returned from each
    step

Definition at line 556 of file interfaces.py.

00556 
00557     def runAllImportStepsFromProfile(profile_id, purge_old=None, ignore_dependencies=False):
00558 
00559         """ Run all setup steps for the given profile in dependency order.
00560 
00561         o 'profile_id' must be a valid ID of a registered profile;
00562            otherwise, raise KeyError.
00563 
00564         o If 'purge_old' is True, then run each step after purging any
00565           "old" setup first (this is the responsibility of the step,
00566           which must check the context we supply).
00567 
00568         o Unless 'ignore_dependencies' is true this will also import
00569           all profiles this profile depends on.
00570 
00571         o Return a mapping, with keys:
00572 
00573           'steps' -- a sequence of IDs of the steps run.
00574 
00575           'messages' -- a dictionary holding messages returned from each
00576             step
00577         """

Here is the caller graph for this function:

Generate a tarball containing artifacts from one export step.

o 'step_id' identifies the export step.

o Return a mapping, with keys:

  'steps' -- a sequence of IDs of the steps run.

  'messages' -- a dictionary holding messages returned from each
    step

  'tarball' -- the stringified tar-gz data.

Definition at line 597 of file interfaces.py.

00597 
00598     def runExportStep( step_id ):
00599 
00600         """ Generate a tarball containing artifacts from one export step.
00601 
00602         o 'step_id' identifies the export step.
00603 
00604         o Return a mapping, with keys:
00605 
00606           'steps' -- a sequence of IDs of the steps run.
00607 
00608           'messages' -- a dictionary holding messages returned from each
00609             step
00610 
00611           'tarball' -- the stringified tar-gz data.
00612         """

def GenericSetup.interfaces.ISetupTool.runImportStep (   step_id,
  run_dependencies = True,
  purge_old = None 
)
Execute a given setup step from the current
_import_context_id context.

o 'step_id' is the ID of the step to run.

o If 'purge_old' is True, then run the step after purging any
  "old" setup first (this is the responsibility of the step,
  which must check the context we supply).

o If 'run_dependencies' is True, then run any out-of-date
  dependency steps first.

o Return a mapping, with keys:

  'steps' -- a sequence of IDs of the steps run.

  'messages' -- a dictionary holding messages returned from each
    step

DEPRECATED.  Use runImportStepFromProfile instead.

Definition at line 532 of file interfaces.py.

00532 
00533     def runImportStep(step_id, run_dependencies=True, purge_old=None):
00534 
00535         """ Execute a given setup step from the current
00536         _import_context_id context.
00537 
00538         o 'step_id' is the ID of the step to run.
00539 
00540         o If 'purge_old' is True, then run the step after purging any
00541           "old" setup first (this is the responsibility of the step,
00542           which must check the context we supply).
00543 
00544         o If 'run_dependencies' is True, then run any out-of-date
00545           dependency steps first.
00546 
00547         o Return a mapping, with keys:
00548 
00549           'steps' -- a sequence of IDs of the steps run.
00550 
00551           'messages' -- a dictionary holding messages returned from each
00552             step
00553 
00554         DEPRECATED.  Use runImportStepFromProfile instead.
00555         """

def GenericSetup.interfaces.ISetupTool.runImportStepFromProfile (   profile_id,
  step_id,
  run_dependencies = True,
  purge_old = None 
)
Execute a given setup step from the given profile.

o 'profile_id' must be a valid ID of a registered profile;
   otherwise, raise KeyError.

o 'step_id' is the ID of the step to run.

o If 'purge_old' is True, then run the step after purging any
  "old" setup first (this is the responsibility of the step,
  which must check the context we supply).

o If 'run_dependencies' is True, then run any out-of-date
  dependency steps first.

o Return a mapping, with keys:

  'steps' -- a sequence of IDs of the steps run.

  'messages' -- a dictionary holding messages returned from each
    step

Definition at line 508 of file interfaces.py.

00508 
00509                                  run_dependencies=True, purge_old=None):
00510 
00511         """ Execute a given setup step from the given profile.
00512 
00513         o 'profile_id' must be a valid ID of a registered profile;
00514            otherwise, raise KeyError.
00515 
00516         o 'step_id' is the ID of the step to run.
00517 
00518         o If 'purge_old' is True, then run the step after purging any
00519           "old" setup first (this is the responsibility of the step,
00520           which must check the context we supply).
00521 
00522         o If 'run_dependencies' is True, then run any out-of-date
00523           dependency steps first.
00524 
00525         o Return a mapping, with keys:
00526 
00527           'steps' -- a sequence of IDs of the steps run.
00528 
00529           'messages' -- a dictionary holding messages returned from each
00530             step
00531         """

Here is the caller graph for this function:

def GenericSetup.interfaces.ISetupTool.setBaselineContext (   context_id,
  encoding = None 
)
Specify the base profile for this configuration.

Definition at line 474 of file interfaces.py.

00474 
00475     def setBaselineContext( context_id, encoding=None):
00476         """ Specify the base profile for this configuration.
00477         """

Here is the caller graph for this function:

Set the ID of the active import context and update the registries.

DEPRECATED.  The idea of a stateful active import context is
going away.

Definition at line 466 of file interfaces.py.

00466 
00467     def setImportContext( context_id ):
00468 
00469         """ Set the ID of the active import context and update the registries.
00470 
00471         DEPRECATED.  The idea of a stateful active import context is
00472         going away.
00473         """


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