eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'ProjectChecker':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: ProjectChecker


Inheritance:

   Object
   |
   +--ProjectChecker

Package:
stx:libbasic3
Category:
System-Support-Projects
Version:
rev: 1.58 date: 2024/03/12 07:14:36
user: cg
file: ProjectChecker.st directory: libbasic3
module: stx stc-classLibrary: libbasic3

Description:


A simple project checker that can search whole projects or individual
classes or methods for various problems that may cause build problems,
such as:
    - inconsistent/messed up project definition class
    - method code problems

NOTE: this is not a lint. It only checks for inconsistent configuration
(projectDefinition class data vs. real data) and compilability (stc limitations).

NOTE: Not yet finished. This code is meant as a single central entry for all the
source code management tools like SCM Utilities, NewSystemBrowser ets. That code
will be refactored later once this tool prooves itself useful and mature enough.


[instance variables:]

[class variables:]

copyright

COPYRIGHT (c) 2006 by eXept Software AG All Rights Reserved This software is furnished under a license and may be used only in accordance with the terms of that license and with the inclusion of the above copyright notice. This software may not be provided or otherwise made available to, or used by, any other person. No title to or ownership of the software is hereby transferred.

Class protocol:

checking
o  check: aPackageSymbolOrClass

instance creation
o  forPackage: packageId

o  new
return an initialized instance


Instance protocol:

accessing
o  checkExtensionsOnly: aBoolean

o  classes: aCollection

o  methods

o  methods: something

o  package: packageOrPackageId
Adds `packageId` to set of checked packages

o  problems

o  skipCheckClasses: aBoolean

checking
o  check

o  check: packageSymbolOrClass
ProjectChecker new check:'stx:libbasic3'
ProjectChecker new check:self

checks-individual
o  checkClassListConsistency
Checks whether all classes listed in #classNamesAndAttributes are present
and if all present classes are listed

o  checkClassesAutoloadedSuperclasse: aCollection
of Class

o  checkClassesForMethodsInNoProject: classesToCheck
Sigh, special hack for Expecco

o  checkClassesForNonQualifiedSharedPools: classesToCheck

o  checkClassesListedInProjectDefinition: classesToCheck

o  checkExtensionsListConsistency
Checks whether all extensions listed in #extensionMethodNames are present
and if all extension methods are listed.
Also check if any regular or extension method is also listed in some other package
(which may happen after a move, if the original package was not updated)

o  checkExtensionsPrerequisites
Checks whether packages of all extensions method classes are listed
in package prerequisites

o  checkMethodCodingStyle: method
Checks for various coding style violations such as 'self halt' or
improper indentation :-)

o  checkMethodSTCCompilability1: method into: problemIssue
Checks is the method can be compiled by STC based on Parser error/warnings

o  checkMethodSTCCompilability2: method into: problemIssue
Check if SmallLint is available...

o  checkMethodSTCCompilability: method
Checks is the method can be compiled by STC (since STC won't compile
everything bytecode compiler/jit compiler does, sigh)

o  checkMethodSourceCode: method
Checks, whether method's source code is both
available and parseable. Return true if the code
is syntactically correct, false otherwise

o  checkSubProjects
Checks whether all subprojects listed in #subprojects are present.

checks-private
o  checkClasses

o  checkClasses: classesToCheck

o  checkMethod: method
OK, method's source code is fine, perform more checks on

o  checkMethods
fix wrong mclass

o  checkMethods: methodsToCheck

o  checkPackage
add more here...

o  verifyMethodDictionaryOf: aClass
self halt.

initialization
o  initialize
Invoked when a new instance is created.

Usage example(s):

super initialize.   -- commented since inherited method does nothing

reporting
o  addProblem: aProjectProblem


Examples:


ProjectChecker check: 'stx:libbasic'
ProjectChecker check: 'stx:libtool'
ProjectChecker check: 'stx:libbasic3'
    


ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Mon, 30 Dec 2024 17:46:59 GMT