Votorola

votorola.a
Class Pollserver

java.lang.Object
  extended by Pollserver

@ThreadSafe
public final class Pollserver
extends Object

A server that provides polls and other voter services.

See Also:
../s/manual.xht#pollserver

Nested Class Summary
static class Pollserver.ConstructionContext
          A context for configuring a pollserver.
static class Pollserver.DatabaseCC
          A context for configuring a PostgreSQL database for a pollserver.
 class Pollserver.Run
          A run of the pollserver.
static class Pollserver.TestUseMode
          A mode of test usage for a pollserver.
static interface Pollserver.UserSession
          A session between a user and a running pollserver.
 
Constructor Summary
Pollserver(String name)
          Constructs a Pollserver.
 
Method Summary
 File inDirectory()
          The base directory ~/votorola/in of the file portion of the input store.
 String name()
          The login name of the account on the local host computer, under which the pollserver's data is stored and its processes are run.
 File outDirectory()
          The base directory ~/votorola/out of the file portion of the output store.
 Poll.PollserverScope scopePoll()
          API for all polls within the scope of this pollserver.
 String serverName()
          The fully qualified name of the computer on which this pollserver is hosted.
 String shortTitle()
          A short version of the title, restricted to roughly SHORT_STRING_LENGTH_MAX characters.
(package private)  File startupConfigurationFile()
          The startup configuration file for this pollserver.
 String summaryDescription()
          A brief description of this pollserver, in sentence form.
 Pollserver.TestUseMode testUseMode()
          The test use mode of this pollserver.
 String title()
          The title of this pollserver, in wiki-style title case (leading letter only).
 File votorolaDirectory()
          The base directory ~/votorola of all pollserver configuration files, where ~ is the home directory of the pollserver account.
 URI wikiLocation()
          The location of the pollwiki, which provides default drafting facilities and knowledge-base services.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Pollserver

public Pollserver(String name)
           throws IOException,
                  ScriptException,
                  URISyntaxException
Constructs a Pollserver.

Parameters:
name - per name()
Throws:
IOException
ScriptException
URISyntaxException
Method Detail

inDirectory

public File inDirectory()
The base directory ~/votorola/in of the file portion of the input store.

See Also:
InputStore

name

public String name()
The login name of the account on the local host computer, under which the pollserver's data is stored and its processes are run.

See Also:
serverName(), ../s/manual.xht#pollserver-name

outDirectory

public File outDirectory()
The base directory ~/votorola/out of the file portion of the output store.

See Also:
OutputStore

scopePoll

public Poll.PollserverScope scopePoll()
API for all polls within the scope of this pollserver.


serverName

public String serverName()
The fully qualified name of the computer on which this pollserver is hosted. For example "pollserver.mydomain.dom". It is used to construct service and return email addresses for the various "serviceEmail" methods.

See Also:
name(), Pollserver.ConstructionContext.setServerName(String)

shortTitle

public String shortTitle()
A short version of the title, restricted to roughly SHORT_STRING_LENGTH_MAX characters. For example, "Toronto".

See Also:
title(), Pollserver.ConstructionContext.setTitle(String,String)

startupConfigurationFile

File startupConfigurationFile()
The startup configuration file for this pollserver. It is located at:

votorolaDirectory/pollserver.js

The language is JavaScript. There are restrictions on the character encoding.


summaryDescription

public String summaryDescription()
A brief description of this pollserver, in sentence form. It is intended for display, for example, as an introductory paragraph.

See Also:
Pollserver.ConstructionContext.setSummaryDescription(String)

testUseMode

public Pollserver.TestUseMode testUseMode()
The test use mode of this pollserver.

See Also:
Pollserver.ConstructionContext.setTestUseMode(Pollserver.TestUseMode)

title

public String title()
The title of this pollserver, in wiki-style title case (leading letter only). Normally it includes the informal name of the pollserver's overall district, such as the town or region. For example, "City of Toronto".

See Also:
shortTitle(), Pollserver.ConstructionContext.setTitle(String,String)

votorolaDirectory

public File votorolaDirectory()
The base directory ~/votorola of all pollserver configuration files, where ~ is the home directory of the pollserver account.


wikiLocation

public URI wikiLocation()
The location of the pollwiki, which provides default drafting facilities and knowledge-base services. It is guaranteed to end with a slash '/' character.

See Also:
Pollserver.ConstructionContext.setWikiLocation(String), Pollserver.ConstructionContext.setWikiLocation(URI), ../s/manual.xht#wiki

Votorola