CustomContext.st
author Jakub Nesveda <jakubnesveda@seznam.cz>
Tue, 28 Oct 2014 09:39:46 +0100
changeset 711 605ab7fc9cd1
parent 685 bc7798e413f6
child 718 ed7514e9d76c
permissions -rw-r--r--
return whole source code when selected interval is empty retrieve selector from method when none selector is specified

"{ Package: 'jn:refactoring_custom' }"

Object subclass:#CustomContext
	instanceVariableNames:''
	classVariableNames:''
	poolDictionaries:''
	category:'Interface-Refactoring-Custom'
!


!CustomContext class methodsFor:'queries'!

isAbstract
    "Return if this class is an abstract class.
     True is returned here for myself only; false for subclasses.
     Abstract subclasses must redefine again."

    ^ self == CustomContext.
! !

!CustomContext methodsFor:'accessing-selection'!

selectedClassCategories
    "a collection with selected class categories"

    self subclassResponsibility

    "Created: / 05-05-2014 / 00:13:34 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
!

selectedClasses
    "a collection with selected classes"

    self subclassResponsibility

    "Created: / 26-04-2014 / 13:13:59 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
    "Modified (comment): / 26-04-2014 / 22:38:18 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
!

selectedCodes
    "a collection with source codes (CustomSourceCodeSelection) 
    with selected interval (exact position in source code) and
    corresponding class, method, selector."

    self subclassResponsibility

    "Created: / 18-08-2014 / 21:28:10 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
!

selectedMethodProtocols
    "a collection with selected method protocols"

    self subclassResponsibility

    "Created: / 05-05-2014 / 00:14:23 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
!

selectedMethods
    "a collection with selected methods"

    self subclassResponsibility

    "Created: / 05-05-2014 / 00:12:35 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
!

selectedPackages
    "a collection with selected packages"

    self subclassResponsibility

    "Created: / 05-05-2014 / 00:12:59 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
!

selectedVariables
    "a collection with selected variables"

    self subclassResponsibility

    "Created: / 05-05-2014 / 00:14:59 / Jakub Nesveda <nesvejak@fit.cvut.cz>"
! !

!CustomContext methodsFor:'testing'!

isInteractiveContext
    "Return true, if this generator/refactoring context is interactive,
     i.e., if it may interact with user (like asking for class name or
     similar) or not. 

     Generally speaking, only top-level context is interactive an only
     if generator/refactoring was triggerred from menu.
    "
    ^ false

    "Created: / 16-09-2014 / 09:22:55 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !

!CustomContext class methodsFor:'documentation'!

version_HG

    ^ '$Changeset: <not expanded> $'
! !