eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'HTTPUtilityService':

Home

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

Class: HTTPUtilityService


Inheritance:

   Object
   |
   +--HTTPService
      |
      +--HTTPSelectorService
         |
         +--HTTPUtilityService

Package:
stx:goodies/webServer
Category:
Net-Communication-HTTP-Services
Version:
rev: 1.14 date: 2018/07/28 08:07:24
user: cg
file: HTTPUtilityService.st directory: goodies/webServer
module: stx stc-classLibrary: webServer
Author:
Claus Gittinger

Description:


experimental

A service which provides cgi-like utilities.
For now there are:

    accessCount     - counts access to the URL passed as urlParameter.
                      Replies with a clack-counter image.
                      To count a page, add the following link to the
                      page:
                        <IMG SRC='/Utilities/accessCounter;URL=<URL-of-Page>'>

more to come

[caveat:]
    some strips only work on a bright background


Class protocol:

image specs
o  defaultDigitStrip
specifies the default digit-image strip to be used

o  digitStrip1
This resource specification was automatically generated
by the ImageEditor of ST/X.

usage example(s):

     self digitStrip1 inspect
     ImageEditor openOnClass:self andSelector:#digitStrip1
     Icon flushCachedIcons

o  digitStrip2
a sample digit-image strip.
To use these images, change #defaultDigitStrip

o  digitStrip3
a sample digit-image strip.
To use these images, change #defaultDigitStrip

o  digitStrip3inv
a sample digit-image strip.
To use these images, change #defaultDigitStrip

o  digitStrip3invMasked
a sample digit-image strip.
To use these images, change #defaultDigitStrip

o  digitStrip4
This resource specification was automatically generated
by the ImageEditor of ST/X.

usage example(s):

     self digitStrip4 inspect
     ImageEditor openOnClass:self andSelector:#digitStrip4
     Icon flushCachedIcons

o  digitStrip5
This resource specification was automatically generated
by the ImageEditor of ST/X.

usage example(s):

     self digitStrip5 inspect
     ImageEditor openOnClass:self andSelector:#digitStrip5
     Icon flushCachedIcons

o  digitStrip6
a sample digit-image strip.
To use these images, change #defaultDigitStrip

o  digitStrip6Masked
This resource specification was automatically generated
by the ImageEditor of ST/X.

usage example(s):

     self digitStrip6Masked inspect
     ImageEditor openOnClass:self andSelector:#digitStrip6Masked
     Icon flushCachedIcons

o  digitStrip7
a sample digit-image strip.
To use these images, change #defaultDigitStrip

o  digitStrip8
This resource specification was automatically generated
by the ImageEditor of ST/X.

usage example(s):

     self digitStrip8 inspect
     ImageEditor openOnClass:self andSelector:#digitStrip8
     Icon flushCachedIcons

o  digitStrip8Masked
This resource specification was automatically generated
by the ImageEditor of ST/X.

usage example(s):

     self digitStrip8Masked inspect
     ImageEditor openOnClass:self andSelector:#digitStrip8Masked
     Icon flushCachedIcons

queries-service
o  linkName
return the default path (with slash)


Instance protocol:

accessing
o  digitStrip: aBitmapImage
argument should be one of my class-side-provided digit strips

actions
o  accessCounter: aRequest
count up and return a counter image for the new count.
Arrice here via the URL:
IMG SRC='/Utilities/accessCounter;url=<countedURL>'

o  accessCounterUncounted: aRequest
return a counter image - but do not count up.
Arrive here via the URL:
IMG SRC='/Utilities/accessCounterUncounted'

helpers
o  generateImageFor: aCount
generate a bitmap image for aCount.
Uses the digitStrip for individual digit-pictures.

usage example(s):

     self new generateImageFor:9876

     (self new digitStrip:(self digitStrip4)) generateImageFor:9876
     (self new digitStrip:(self digitStrip6)) generateImageFor:9876
     (self new digitStrip:(self digitStrip7)) generateImageFor:9876

initialization
o  initialize
look should be configurable via a settings app

queries-service
o  allowedMessages
return a collection of messages, that this service processes



ST/X 7.2.0.0; WebServer 1.670 at bd0aa1f87cdd.unknown:8081; Fri, 16 Apr 2021 10:54:00 GMT