# eric6.Plugins.VcsPlugins.vcsMercurial.QueuesExtension.queues

Module implementing the queues extension interface.

### Global Attributes

None

### Classes

Queues | Class implementing the queues extension interface.

### Functions

None

## Queues

Class implementing the queues extension interface.

### Derived from

HgExtension

### Class Attributes

APPLIED_LIST
GOTO
POP
PUSH
QUEUE_ACTIVATE
QUEUE_DELETE
QUEUE_PURGE
SERIES_LIST
UNAPPLIED_LIST

### Class Methods

None

### Methods

Queues | Constructor
__getCommitMessage | Private method to get the commit message of the current patch.
__getCurrentPatch | Private method to get the name of the current patch.
__getPatchesList | Private method to get a list of patches of a given type.
getGuardsList | Public method to get a list of all guards defined.
hgQueueCreateRenameQueue | Public method to create a new queue or rename the active queue.
hgQueueDeletePatch | Public method to delete a selected unapplied patch.
hgQueueDeletePurgeActivateQueue | Public method to delete the reference to a queue and optionally remove the patch directory or set the active queue.
hgQueueFinishAppliedPatches | Public method to finish all applied patches.
hgQueueFoldUnappliedPatches | Public method to fold patches into the current patch.
hgQueueGuardsDeactivate | Public method to deactivate all active guards.
hgQueueGuardsDefine | Public method to define guards for the current or a named patch.
hgQueueGuardsDropAll | Public method to drop all guards of the current or a named patch.
hgQueueGuardsIdentifyActive | Public method to list all active guards.
hgQueueGuardsList | Public method to list the guards for the current or a named patch.
hgQueueGuardsListAll | Public method to list all guards of all patches.
hgQueueGuardsSetActive | Public method to set the active guards.
hgQueueInit | Public method to initialize a new queue repository.
hgQueueListPatches | Public method to show a list of all patches.
hgQueueListQueues | Public method to list available queues.
hgQueueNewPatch | Public method to create a new named patch.
hgQueuePushPopPatches | Public method to push patches onto the stack or pop patches off the stack.
hgQueueRefreshPatch | Public method to refresh the current patch.
hgQueueRenamePatch | Public method to rename the current or a selected patch.
hgQueueShowHeader | Public method to show the commit message of the current patch.
hgQueueShowPatch | Public method to show the contents of the current patch.
hgQueueStatus | Public method used to view the status of a queue repository.
shutdown | Public method used to shutdown the queues interface.

### Static Methods

None

#### Queues (Constructor)

Queues(vcs)

Constructor

vcs
  reference to the Mercurial vcs object

#### Queues.__getCommitMessage

__getCommitMessage(repodir)

Private method to get the commit message of the current patch.

repodir
  directory name of the repository (string)

Returns:
  name of the current patch (string)

#### Queues.__getCurrentPatch

__getCurrentPatch(repodir)

Private method to get the name of the current patch.

repodir
  directory name of the repository (string)

Returns:
  name of the current patch (string)

#### Queues.__getPatchesList

__getPatchesList(repodir, listType, withSummary=False)

Private method to get a list of patches of a given type.

repodir
  directory name of the repository (string)
listType
  type of patches list to get (Queues.APPLIED_LIST, Queues.UNAPPLIED_LIST, Queues.SERIES_LIST)
withSummary
  flag indicating to get a summary as well (boolean)

Returns:
  list of patches (list of string)

Raises ValueError:
  raised to indicate an invalid patch list type

#### Queues.getGuardsList

getGuardsList(repodir, allGuards=True)

Public method to get a list of all guards defined.

repodir
  directory name of the repository (string)
allGuards
  flag indicating to get all guards (boolean)

Returns:
  sorted list of guards (list of strings)

#### Queues.hgQueueCreateRenameQueue

hgQueueCreateRenameQueue(name, isCreate)

Public method to create a new queue or rename the active queue.

name
  file/directory name (string)
isCreate
  flag indicating to create a new queue (boolean)

#### Queues.hgQueueDeletePatch

hgQueueDeletePatch(name)

Public method to delete a selected unapplied patch.

name
  file/directory name (string)

#### Queues.hgQueueDeletePurgeActivateQueue

hgQueueDeletePurgeActivateQueue(name, operation)

Public method to delete the reference to a queue and optionally remove the patch directory or set the active queue.

name
  file/directory name (string)
operation
  operation to be performed (Queues.QUEUE_DELETE, Queues.QUEUE_PURGE, Queues.QUEUE_ACTIVATE)

Raises ValueError:
  raised to indicate an invalid operation

#### Queues.hgQueueFinishAppliedPatches

hgQueueFinishAppliedPatches(name)

Public method to finish all applied patches.

name
  file/directory name (string)

#### Queues.hgQueueFoldUnappliedPatches

hgQueueFoldUnappliedPatches(name)

Public method to fold patches into the current patch.

name
  file/directory name (string)

#### Queues.hgQueueGuardsDeactivate

hgQueueGuardsDeactivate(name)

Public method to deactivate all active guards.

name
  file/directory name (string)

#### Queues.hgQueueGuardsDefine

hgQueueGuardsDefine(name)

Public method to define guards for the current or a named patch.

name
  file/directory name (string)

#### Queues.hgQueueGuardsDropAll

hgQueueGuardsDropAll(name)

Public method to drop all guards of the current or a named patch.

name
  file/directory name (string)

#### Queues.hgQueueGuardsIdentifyActive

hgQueueGuardsIdentifyActive(name)

Public method to list all active guards.

name
  file/directory name (string)

#### Queues.hgQueueGuardsList

hgQueueGuardsList(name)

Public method to list the guards for the current or a named patch.

name
  file/directory name (string)

#### Queues.hgQueueGuardsListAll

hgQueueGuardsListAll(name)

Public method to list all guards of all patches.

name
  file/directory name (string)

#### Queues.hgQueueGuardsSetActive

hgQueueGuardsSetActive(name)

Public method to set the active guards.

name
  file/directory name (string)

#### Queues.hgQueueInit

hgQueueInit(name)

Public method to initialize a new queue repository.

name
  directory name (string)

#### Queues.hgQueueListPatches

hgQueueListPatches(name)

Public method to show a list of all patches.

name
  file/directory name (string)

#### Queues.hgQueueListQueues

hgQueueListQueues(name)

Public method to list available queues.

name
  file/directory name (string)

#### Queues.hgQueueNewPatch

hgQueueNewPatch(name)

Public method to create a new named patch.

name
  file/directory name (string)

#### Queues.hgQueuePushPopPatches

hgQueuePushPopPatches(name, operation, doAll=False, named=False, force=False)

Public method to push patches onto the stack or pop patches off the stack.

name
  file/directory name (string)
operation
  operation type to be performed (Queues.POP, Queues.PUSH, Queues.GOTO)
doAll=
  flag indicating to push/pop all (boolean)
named=
  flag indicating to push/pop until a named patch is at the top of the stack (boolean)
force=
  flag indicating a forceful pop (boolean)

Returns:
  flag indicating that the project should be reread (boolean)

Raises ValueError:
  raised to indicate an invalid operation

#### Queues.hgQueueRefreshPatch

hgQueueRefreshPatch(name, editMessage=False)

Public method to refresh the current patch.

name
  file/directory name (string)
editMessage
  flag indicating to edit the current commit message (boolean)

#### Queues.hgQueueRenamePatch

hgQueueRenamePatch(name)

Public method to rename the current or a selected patch.

name
  file/directory name (string)

#### Queues.hgQueueShowHeader

hgQueueShowHeader(name)

Public method to show the commit message of the current patch.

name
  file/directory name (string)

#### Queues.hgQueueShowPatch

hgQueueShowPatch(name)

Public method to show the contents of the current patch.

name
  file/directory name (string)

#### Queues.hgQueueStatus

hgQueueStatus(name)

Public method used to view the status of a queue repository.

name
  directory name (string)

#### Queues.shutdown

shutdown()

Public method used to shutdown the queues interface.

Up