BBjServletConfiguration::getConfig

BBjServlets are deprecated for BBj 21.00 and higher, and have been replaced by BBxServlets.

Description

In BBj 15.00 and higher, this method gets the name of the config file used in executing a BBj Servlet.

Syntax

Return Value

Method

string

getConfig()

Parameters

None.

Return Value

Returns the full/path/to/config.bbj.

Remarks

None.

Example

declare BBjAPI api!
declare BBjAdmin admin!
declare BBjJettyServerConfiguration config!
declare BBjJettyContextConfiguration root!
api! = BBJAPI()
admin! = api!.getAdmin("admin","admin123")
config! = admin!.getJettyServerConfig()
root! = config!.getRootContextInfo()

rem '-- Get ALL the servlets from the root context and print their configuration
vect_servlets! = root!.getServlets()
sz = vect_servlets!.size()
if (sz) then
    for i = 0 to sz-1
        declare BBjServletConfiguration servletConfig!
        servletConfig! = cast(BBjServletConfiguration,vect_servlets!.get(i))
        print "SERVLET NAME:" + str(servletConfig!.getName())
        print "SERVLET PROGRAM:" + str(servletConfig!.getProgram())
        print "SERVLET CONFIG:" + str(servletConfig!.getConfig())
    next i
endif

See Also

BBjAPI

BBj Servlet

See the BBj Object Diagram for an illustration of the relationship between BBj Objects.