Amiro.CMS API Reference
Amiro.Ru / Manual
Loading search...

The AMI_Package_InstanceManipulator class

AMI_Package_Manipulator
   |
   --AMI_Package_InstanceManipulator

• Introduction

Abstract class for transaction manipulating CMS module.

• Class synopsis

AMI_Package_InstanceManipulator extends AMI_Package_Manipulator {
/* Properties */
// Processed module Ids
public static array $aProcessedEntities = array();
// Package info
protected array $aPkgInfo;
// Flag specifying hypermodule/config is single instanced
protected bool $isSingleInstance;
// Module Id
protected string $modId;
// Package Id
protected string $pkgId;
// Hypermodule/config for single instanced or module Id
protected string $processingEntity;
// Module section
protected string $section;
// Module tab order
protected string $tabOrder;
/* Inherited Properties */
// Array containing class methods to run
protected AMI_Package_Manipulator::$aActions = array();
// Array of transactions
protected AMI_Package_Manipulator::$aTx = array();
// Used to store previous exception
// Name for transactions, must be filled in children
/* Methods */
// Resource list filter callback.
protected cbFilterResourceList ( string $file ) returns bool;
// Transaction action.
protected checkProcessed ( ) returns void;
// Returns config resource content.
protected getContentByResource ( string $resource ) returns string;
// Returns resources by type.
protected getResources ( string $type ) returns array;
// Initialization.
protected init ( ) returns void;
// Returns TRUE if hypermodule/config specifies meta has according property.
protected isSingleInstance ( ) returns bool;
// Validates initial data.
protected validate ( ) returns void;
/* Inherited Methods */
// Do actions.
public AMI_Package_Manipulator::doActions ( ) returns void;
// Runs transactions.
public AMI_Package_Manipulator::run ( ) returns void;
// Adds action.
protected AMI_Package_Manipulator::addAction ( string $method, [ $aArgs = null ] ) returns void;
// Commits transactions.
protected AMI_Package_Manipulator::commit ( ) returns void;
// Converts mode to string representation for logging.
protected AMI_Package_Manipulator::getModeAsString ( int $mode ) returns string;
// Initializes transactions.
protected AMI_Package_Manipulator::initTx ( ) returns void;
// Rollbacks transactions.
protected AMI_Package_Manipulator::rollback ( [ int $index = 0 ] ) returns void;
// Validates initial data.
protected AMI_Package_Manipulator::validate ( ) returns void;
}
Tags:
since 6.0.2

• Class Properies

public static array $aProcessedEntities

Processed module Ids

Stores installed/uninstalled module Ids or hypermodule/config for single instanced modules

protected array $aPkgInfo

Package info

protected bool $isSingleInstance

Flag specifying hypermodule/config is single instanced

protected string $modId

Module Id

protected string $pkgId

Package Id

protected string $processingEntity

Hypermodule/config for single instanced or module Id

protected string $section

Module section

protected string $tabOrder

Module tab order

• Class Methods

// Resource list filter callback.
protected cbFilterResourceList ( string $file ) returns bool;
  • string $file
    Path to the file
Tags:
see AMI_Package::getResources()
// Transaction action.
protected checkProcessed ( ) returns void;
Checks processed entities.
Tags:
throws AMI_Package_Exception In case of problems.
// Returns config resource content.
protected getContentByResource ( string $resource ) returns string;
  • string $resource
    Path to resource
// Returns resources by type.
protected getResources ( string $type ) returns array;
  • string $type
    Resource type
// Initialization.
protected init ( ) returns void;
// Returns TRUE if hypermodule/config specifies meta has according property.
protected isSingleInstance ( ) returns bool;
// Validates initial data.
protected validate ( ) returns void;