//# 15 errors, 322 messages
//#
/*
    //#WeblogRequest.java:1:1: class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
 * Licensed to the Apache Software Foundation (ASF) under one or more
 *  contributor license agreements.  The ASF licenses this file to You
 * under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.  For additional information regarding
 * copyright in this work, please see the NOTICE file in the top level
 * directory of this distribution.
 */

package org.apache.roller.weblogger.ui.rendering.util;

import java.util.Locale;
import javax.servlet.http.HttpServletRequest;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.roller.weblogger.WebloggerException;
import org.apache.roller.weblogger.business.WebloggerFactory;
import org.apache.roller.weblogger.business.UserManager;
import org.apache.roller.weblogger.pojos.Weblog;


/**
 * Represents a request to a weblog.
 * 
 * This is a fairly generic parsed request which is only trying to figure out
 * the elements of a weblog request which apply to all weblogs.  We try to 
 * determine the weblogHandle, if a locale was specified, and then what extra 
 * path info remains.  The basic format is like this ...
 * 
 * /<weblogHandle>[/locale][/extra/path/info]
 * 
 * All weblog urls require a weblogHandle, so we ensure that part of the url is
 * properly specified.  locale is always optional, so we do our best to see
 * if a locale is specified.  and path info is always optional.
 *
 * NOTE: this class purposely exposes a getPathInfo() method which provides the
 * path info specified by the request that has not been parsed by this
 * particular class.  this makes it relatively easy for subclasses to extend
 * this class and simply pick up where it left off in the parsing process.
 */
public class WeblogRequest extends ParsedRequest {
    
    private static Log log = LogFactory.getLog(WeblogRequest.class);
    //#WeblogRequest.java:52: method: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init
    //#WeblogRequest.java:52: Warning: method not available
    //#    -- call on Log org.apache.commons.logging.LogFactory:getLog(Class)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init
    //#    unanalyzed callee: Log org.apache.commons.logging.LogFactory:getLog(Class)
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogRequest]
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getAuthenticUser()Ljava/lang/String;
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getLocale()Ljava/lang/String;
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getLocaleInstance()Ljava/util/Locale;
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getPathInfo()Ljava/lang/String;
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getUser()Lorg/apache/roller/weblogger/pojos/User;
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getWeblogHandle()Ljava/lang/String;
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.isLoggedIn()Z
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setAuthenticUser(Ljava/lang/String;)V
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setLocale(Ljava/lang/String;)V
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setLocaleInstance(Ljava/util/Locale;)V
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setPathInfo(Ljava/lang/String;)V
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setUser(Lorg/apache/roller/weblogger/pojos/User;)V
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setWeblog(Lorg/apache/roller/weblogger/pojos/Weblog;)V
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setWeblogHandle(Ljava/lang/String;)V
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): log
    //#output(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): org/apache/roller/weblogger/ui/rendering/util/ParsedRequest.__Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogRequest]
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogRequest] == &__Dispatch_Table
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): org/apache/roller/weblogger/ui/rendering/util/ParsedRequest.__Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogRequest] == &__Dispatch_Table
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getAuthenticUser()Ljava/lang/String; == &org/apache/roller/weblogger/ui/rendering/util/ParsedRequest.getAuthenticUser
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getLocale()Ljava/lang/String; == &getLocale
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getLocaleInstance()Ljava/util/Locale; == &getLocaleInstance
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getPathInfo()Ljava/lang/String; == &getPathInfo
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getUser()Lorg/apache/roller/weblogger/pojos/User; == &org/apache/roller/weblogger/ui/rendering/util/ParsedRequest.getUser
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog; == &getWeblog
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.getWeblogHandle()Ljava/lang/String; == &getWeblogHandle
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.isLocale(Ljava/lang/String;)Z == &isLocale
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.isLoggedIn()Z == &org/apache/roller/weblogger/ui/rendering/util/ParsedRequest.isLoggedIn
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setAuthenticUser(Ljava/lang/String;)V == &org/apache/roller/weblogger/ui/rendering/util/ParsedRequest.setAuthenticUser
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setLocale(Ljava/lang/String;)V == &setLocale
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setLocaleInstance(Ljava/util/Locale;)V == &setLocaleInstance
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setPathInfo(Ljava/lang/String;)V == &setPathInfo
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setUser(Lorg/apache/roller/weblogger/pojos/User;)V == &org/apache/roller/weblogger/ui/rendering/util/ParsedRequest.setUser
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setWeblog(Lorg/apache/roller/weblogger/pojos/Weblog;)V == &setWeblog
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): __Dispatch_Table.setWeblogHandle(Ljava/lang/String;)V == &setWeblogHandle
    //#post(org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init): init'ed(log)
    //#WeblogRequest.java:52: end of method: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.org.apache.roller.weblogger.ui.rendering.util.WeblogRequest__static_init
    
    // lightweight attributes
    private String weblogHandle = null;
    private String locale = null;
    private String pathInfo = null;
    
    // heavyweight attributes
    private Weblog weblog = null;
    private Locale localeInstance = null;
    
    
    public WeblogRequest() {}
    //#WeblogRequest.java:64: method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.authenticUser
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.locale
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.localeInstance
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.pathInfo
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.request
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.user
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.weblog
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.weblogHandle
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.authenticUser == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.locale == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.localeInstance == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.pathInfo == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.request == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.user == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.weblog == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()): this.weblogHandle == null
    //#WeblogRequest.java:64: end of method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.org.apache.roller.weblogger.ui.rendering.util.WeblogRequest()
    
    
    public WeblogRequest(HttpServletRequest request) 
            throws InvalidRequestException {
        
        // let our parent take care of their business first
        super(request);
    //#WeblogRequest.java:71: method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#WeblogRequest.java:71: Warning: suspicious precondition
    //#    the precondition for this.__Tag is not a contiguous range of values
    //#    severity: SUPPRESSED
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    suspicious precondition index: [2]
    //#    Attribs:  Soft
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): "handle = "._tainted
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): "locale = "._tainted
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): "not a weblog request, "._tainted
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): "parsing path "._tainted
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): "pathInfo = "._tainted
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogCommentRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogFeedRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogPageRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewResourceRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogResourceRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogSearchRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogTrackbackRequest]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Descendant_Table[others]
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): __Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): log
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogCommentRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogFeedRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogPageRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewResourceRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogResourceRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogSearchRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org/apache/roller/weblogger/ui/rendering/util/WeblogTrackbackRequest.__Dispatch_Table.isLocale(Ljava/lang/String;)Z
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): request
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this
    //#input(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.__Tag
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): java.lang.String:substring(...)._tainted
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.__Tag
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.authenticUser
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.locale
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.localeInstance
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.pathInfo
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.request
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.user
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.weblog
    //#output(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.weblogHandle
    //#new obj(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): java.lang.String:substring(...)
    //#pre[1] (void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): log != null
    //#pre[3] (void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): request != null
    //#pre[2] (void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): (soft) this.__Tag in {org/apache/roller/weblogger/ui/rendering/util/WeblogCommentRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogFeedRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPageRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewResourceRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogResourceRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogSearchRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogTrackbackRequest}
    //#presumption(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): java.lang.String:length(...)@89 >= 1
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): java.lang.String:substring(...)._tainted == 0
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.__Tag == old this.__Tag
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): (soft) this.__Tag in {org/apache/roller/weblogger/ui/rendering/util/WeblogCommentRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogFeedRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPageRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewResourceRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogResourceRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogSearchRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogTrackbackRequest}
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): init'ed(this.authenticUser)
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): init'ed(this.locale)
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.localeInstance == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.user == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.weblog == null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): init'ed(this.pathInfo)
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.request == request
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.request != null
    //#post(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): this.weblogHandle == null
    //#unanalyzed(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): Effects-of-calling:java.lang.String:length
    //#unanalyzed(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): Effects-of-calling:java.lang.String:split
    //#unanalyzed(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): Effects-of-calling:org.apache.roller.weblogger.WebloggerException
    //#unanalyzed(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): Effects-of-calling:javax.servlet.http.HttpServletRequest:getUserPrincipal
    //#unanalyzed(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): Effects-of-calling:java.security.Principal:getName
    //#test_vector(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): java.lang.String:endsWith(...)@84: {0}, {1}
    //#test_vector(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): java.lang.String:length(...)@106: {0}, {1..4_294_967_295}
    //#test_vector(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): java.lang.String:length(...)@78: {0,1}, {2..4_294_967_295}
    //#test_vector(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): javax.servlet.http.HttpServletRequest:getPathInfo(...)@73: Addr_Set{null}, Inverse{null}
    //#test_vector(void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)): org.apache.commons.logging.Log:isDebugEnabled(...)@122: {0}, {1}
        
        String path = request.getPathInfo();
        
        log.debug("parsing path "+path);
    //#WeblogRequest.java:75: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
        
        // first, cleanup extra slashes and extract the weblog weblogHandle
        if(path != null && path.trim().length() > 1) {
            
            // strip off the leading slash
            path = path.substring(1);
            
            // strip off trailing slash if needed
            if(path.endsWith("/")) {
                path = path.substring(0, path.length() - 1);
            }
            
            String[] pathElements = path.split("/", 2);
            if(pathElements[0].trim().length() > 0) {
    //#WeblogRequest.java:89: ?use of default init
    //#    init'ed(pathElements.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_5
    //#    assertion: init'ed(pathElements.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:89: ?use of default init
    //#    init'ed(pathElements[0])
    //#    severity: SUPPRESSED
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_5
    //#    assertion: init'ed(pathElements[0])
    //#    VN: undefined
    //#    Expected: Univ-VN-Set
    //#    Bad: {Invalid}
    //#    Attribs:  Ptr  Bad only invalid
    //#WeblogRequest.java:89: ?null dereference
    //#    not_init'ed(pathElements[0])
    //#    severity: MEDIUM
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_5
    //#    assertion: not_init'ed(pathElements[0])
    //#    VN: undefined
    //#    Expected: Inverse{null} or Invalid
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad
                this.weblogHandle = pathElements[0];
    //#WeblogRequest.java:90: ?use of default init
    //#    init'ed(pathElements.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_6
    //#    assertion: init'ed(pathElements.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:90: ?use of default init
    //#    init'ed(pathElements[0])
    //#    severity: SUPPRESSED
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_6
    //#    assertion: init'ed(pathElements[0])
    //#    VN: undefined
    //#    Expected: Univ-VN-Set
    //#    Bad: {Invalid}
    //#    Attribs:  Ptr  Bad only invalid
            } else {
                // no weblogHandle in path info
                throw new InvalidRequestException("not a weblog request, "+
                        request.getRequestURL());
            }
            
            // if there is more left of the path info then hold onto it
            if(pathElements.length == 2) {
    //#WeblogRequest.java:98: ?use of default init
    //#    init'ed(pathElements.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_8
    //#    assertion: init'ed(pathElements.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:98: Warning: test always goes same way
    //#    test predetermined because pathElements.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    from bb: bb_8
    //#    live edge: bb_8-->bb_10
    //#    tested vn: undefined - 2
    //#    tested vn values: {-2}
                path = pathElements[1];
    //#WeblogRequest.java:99: Warning: dead code
    //#    dead code here because pathElements.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    dead bb: bb_9
            } else {
                path = null;
            }
        }
        
        // second, check if we have a locale, everything else is extra path info
        if(path != null && path.trim().length() > 0) {
            
            String[] pathElements = path.split("/", 2);
            if(this.isLocale(pathElements[0])) {
    //#WeblogRequest.java:109: ?use of default init
    //#    init'ed(pathElements.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_13
    //#    assertion: init'ed(pathElements.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:109: ?use of default init
    //#    init'ed(pathElements[0])
    //#    severity: SUPPRESSED
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_13
    //#    assertion: init'ed(pathElements[0])
    //#    VN: undefined
    //#    Expected: Univ-VN-Set
    //#    Bad: {Invalid}
    //#    Attribs:  Ptr  Bad only invalid
    //#WeblogRequest.java:109: Warning: test always goes same way
    //#    test predetermined because isLocale(...) == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    from bb: bb_13
    //#    live edge: bb_13-->bb_16
    //#    tested vn: isLocale(...)
    //#    tested vn values: {0}
                this.locale = pathElements[0];
    //#WeblogRequest.java:110: Warning: dead code
    //#    dead code here because isLocale(...) == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    dead bb: bb_14
                
                // everything else is path info
                if(pathElements.length == 2) {
                    this.pathInfo = pathElements[1];
    //#WeblogRequest.java:114: Warning: dead code continues
    //#    dead code continues
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    dead bb: bb_15
                }
            } else {
                // no locale, just extra path info
                this.pathInfo = path;
            }
        }
        
        if(log.isDebugEnabled()) {
    //#WeblogRequest.java:122: Warning: method not available
    //#    -- call on bool org.apache.commons.logging.Log:isDebugEnabled()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    unanalyzed callee: bool org.apache.commons.logging.Log:isDebugEnabled()
            log.debug("handle = "+this.weblogHandle);
    //#WeblogRequest.java:123: ?use of default init
    //#    init'ed(this.weblogHandle)
    //#    severity: SUPPRESSED
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    basic block: bb_18
    //#    assertion: init'ed(this.weblogHandle)
    //#    VN: this.weblogHandle
    //#    Expected: Univ-VN-Set
    //#    Bad: {Invalid}
    //#    Attribs:  Ptr  Bad only invalid
    //#WeblogRequest.java:123: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
            log.debug("locale = "+this.locale);
    //#WeblogRequest.java:124: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
            log.debug("pathInfo = "+this.pathInfo);
    //#WeblogRequest.java:125: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
        }
    }
    //#WeblogRequest.java:127: end of method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.org.apache.roller.weblogger.ui.rendering.util.WeblogRequest(HttpServletRequest)
    

    /**
     * Convenience method which determines if the given string is a valid
     * locale string.
     */
    protected boolean isLocale(String potentialLocale) {
        
        boolean isLocale = false;
    //#WeblogRequest.java:136: method: bool org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.isLocale(String)
    //#input(bool isLocale(String)): potentialLocale
    //#input(bool isLocale(String)): potentialLocale._tainted
    //#output(bool isLocale(String)): return_value
    //#post(bool isLocale(String)): return_value == 0
    //#test_vector(bool isLocale(String)): potentialLocale: Addr_Set{null}, Inverse{null}
    //#test_vector(bool isLocale(String)): java.lang.String:length(...)@139: {2}, {0,1, 3..4_294_967_295}
    //#test_vector(bool isLocale(String)): java.lang.String:length(...)@139: {0..4, 6..4_294_967_295}, {5}
        
        // we only support 2 or 5 character locale strings, so check that first
        if(potentialLocale != null && 
                (potentialLocale.length() == 2 || potentialLocale.length() == 5)) {
            
            // now make sure that the format is proper ... e.g. "en_US"
            // we are not going to be picky about capitalization
            String[] langCountry = potentialLocale.split("_");
            if(langCountry.length == 1 && 
    //#WeblogRequest.java:145: ?use of default init
    //#    init'ed(langCountry.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    basic block: bb_4
    //#    assertion: init'ed(langCountry.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:145: Warning: test always goes same way
    //#    test predetermined because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    from bb: bb_4
    //#    live edge: bb_4-->bb_8
    //#    tested vn: undefined - 1
    //#    tested vn values: {-1}
    //#WeblogRequest.java:145: Warning: dead code
    //#    dead code here because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_5
    //#WeblogRequest.java:145: Warning: dead code continues
    //#    dead code continues
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_6
                    langCountry[0] != null && langCountry[0].length() == 2) {
                isLocale = true;
    //#WeblogRequest.java:147: Warning: dead code continues
    //#    dead code continues
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_7
                
            } else if(langCountry.length == 2 && 
    //#WeblogRequest.java:149: ?use of default init
    //#    init'ed(langCountry.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    basic block: bb_8
    //#    assertion: init'ed(langCountry.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:149: Warning: test always goes same way
    //#    test predetermined because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    from bb: bb_8
    //#    live edge: bb_8-->bb_14
    //#    tested vn: undefined - 2
    //#    tested vn values: {-2}
    //#WeblogRequest.java:149: Warning: dead code
    //#    dead code here because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_9
    //#WeblogRequest.java:149: Warning: dead code continues
    //#    dead code continues
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_10
    //#WeblogRequest.java:149: Warning: dead code continues
    //#    dead code continues
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_11
    //#WeblogRequest.java:149: Warning: dead code continues
    //#    dead code continues
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_12
                    langCountry[0] != null && langCountry[0].length() == 2 && 
                    langCountry[1] != null && langCountry[1].length() == 2) {
                
                isLocale = true;
    //#WeblogRequest.java:153: Warning: dead code continues
    //#    dead code continues
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: bool isLocale(String)
    //#    dead bb: bb_13
            }
        }
        
        return isLocale;
    //#WeblogRequest.java:157: end of method: bool org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.isLocale(String)
    }
    
    
    public String getWeblogHandle() {
        return weblogHandle;
    //#WeblogRequest.java:162: method: String org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getWeblogHandle()
    //#input(String getWeblogHandle()): this
    //#input(String getWeblogHandle()): this.weblogHandle
    //#output(String getWeblogHandle()): return_value
    //#pre[2] (String getWeblogHandle()): init'ed(this.weblogHandle)
    //#post(String getWeblogHandle()): return_value == this.weblogHandle
    //#post(String getWeblogHandle()): init'ed(return_value)
    //#WeblogRequest.java:162: end of method: String org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getWeblogHandle()
    }

    public void setWeblogHandle(String weblogHandle) {
        this.weblogHandle = weblogHandle;
    //#WeblogRequest.java:166: method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setWeblogHandle(String)
    //#input(void setWeblogHandle(String)): this
    //#input(void setWeblogHandle(String)): weblogHandle
    //#output(void setWeblogHandle(String)): this.weblogHandle
    //#post(void setWeblogHandle(String)): this.weblogHandle == weblogHandle
    //#post(void setWeblogHandle(String)): init'ed(this.weblogHandle)
    }
    //#WeblogRequest.java:167: end of method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setWeblogHandle(String)
    
    public String getLocale() {
        return locale;
    //#WeblogRequest.java:170: method: String org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getLocale()
    //#input(String getLocale()): this
    //#input(String getLocale()): this.locale
    //#output(String getLocale()): return_value
    //#pre[2] (String getLocale()): init'ed(this.locale)
    //#post(String getLocale()): return_value == this.locale
    //#post(String getLocale()): init'ed(return_value)
    //#WeblogRequest.java:170: end of method: String org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getLocale()
    }

    public void setLocale(String locale) {
        this.locale = locale;
    //#WeblogRequest.java:174: method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setLocale(String)
    //#input(void setLocale(String)): locale
    //#input(void setLocale(String)): this
    //#output(void setLocale(String)): this.locale
    //#post(void setLocale(String)): this.locale == locale
    //#post(void setLocale(String)): init'ed(this.locale)
    }
    //#WeblogRequest.java:175: end of method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setLocale(String)

    public String getPathInfo() {
        return pathInfo;
    //#WeblogRequest.java:178: method: String org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getPathInfo()
    //#input(String getPathInfo()): this
    //#input(String getPathInfo()): this.pathInfo
    //#output(String getPathInfo()): return_value
    //#pre[2] (String getPathInfo()): init'ed(this.pathInfo)
    //#post(String getPathInfo()): return_value == this.pathInfo
    //#post(String getPathInfo()): init'ed(return_value)
    //#WeblogRequest.java:178: end of method: String org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getPathInfo()
    }

    public void setPathInfo(String pathInfo) {
        this.pathInfo = pathInfo;
    //#WeblogRequest.java:182: method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setPathInfo(String)
    //#input(void setPathInfo(String)): pathInfo
    //#input(void setPathInfo(String)): this
    //#output(void setPathInfo(String)): this.pathInfo
    //#post(void setPathInfo(String)): this.pathInfo == pathInfo
    //#post(void setPathInfo(String)): init'ed(this.pathInfo)
    }
    //#WeblogRequest.java:183: end of method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setPathInfo(String)

    public Weblog getWeblog() {
        
        if(weblog == null && weblogHandle != null) {
    //#WeblogRequest.java:187: method: Weblog org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getWeblog()
    //#input(Weblog getWeblog()): "Error looking up weblog "._tainted
    //#input(Weblog getWeblog()): java.lang.Boolean.TRUE
    //#input(Weblog getWeblog()): log
    //#input(Weblog getWeblog()): this
    //#input(Weblog getWeblog()): this.weblog
    //#input(Weblog getWeblog()): this.weblogHandle
    //#input(Weblog getWeblog()): this.weblogHandle._tainted
    //#output(Weblog getWeblog()): return_value
    //#output(Weblog getWeblog()): this.weblog
    //#pre[5] (Weblog getWeblog()): init'ed(this.weblog)
    //#pre[4] (Weblog getWeblog()): (soft) log != null
    //#pre[8] (Weblog getWeblog()): (soft) init'ed(this.weblogHandle)
    //#presumption(Weblog getWeblog()): init'ed(java.lang.Boolean.TRUE)
    //#presumption(Weblog getWeblog()): org.apache.roller.weblogger.business.Weblogger:getUserManager(...)@189 != null
    //#presumption(Weblog getWeblog()): org.apache.roller.weblogger.business.WebloggerFactory:getWeblogger(...)@189 != null
    //#post(Weblog getWeblog()): init'ed(return_value)
    //#post(Weblog getWeblog()): this.weblog == return_value
    //#test_vector(Weblog getWeblog()): this.weblog: Inverse{null}, Addr_Set{null}
    //#test_vector(Weblog getWeblog()): this.weblogHandle: Addr_Set{null}, Inverse{null}
            try {
                UserManager umgr = WebloggerFactory.getWeblogger().getUserManager();
    //#WeblogRequest.java:189: Warning: method not available
    //#    -- call on Weblogger org.apache.roller.weblogger.business.WebloggerFactory:getWeblogger()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Weblog getWeblog()
    //#    unanalyzed callee: Weblogger org.apache.roller.weblogger.business.WebloggerFactory:getWeblogger()
    //#WeblogRequest.java:189: Warning: method not available
    //#    -- call on UserManager org.apache.roller.weblogger.business.Weblogger:getUserManager()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Weblog getWeblog()
    //#    unanalyzed callee: UserManager org.apache.roller.weblogger.business.Weblogger:getUserManager()
                weblog = umgr.getWebsiteByHandle(weblogHandle, Boolean.TRUE);
    //#WeblogRequest.java:190: Warning: method not available
    //#    -- call on Weblog org.apache.roller.weblogger.business.UserManager:getWebsiteByHandle(String, Boolean)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Weblog getWeblog()
    //#    unanalyzed callee: Weblog org.apache.roller.weblogger.business.UserManager:getWebsiteByHandle(String, Boolean)
            } catch (WebloggerException ex) {
                log.error("Error looking up weblog "+weblogHandle, ex);
    //#WeblogRequest.java:192: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:error(Object, Throwable)
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Weblog getWeblog()
    //#    unanalyzed callee: void org.apache.commons.logging.Log:error(Object, Throwable)
            }
        }
        
        return weblog;
    //#WeblogRequest.java:196: end of method: Weblog org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getWeblog()
    }

    public void setWeblog(Weblog weblog) {
        this.weblog = weblog;
    //#WeblogRequest.java:200: method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setWeblog(Weblog)
    //#input(void setWeblog(Weblog)): this
    //#input(void setWeblog(Weblog)): weblog
    //#output(void setWeblog(Weblog)): this.weblog
    //#post(void setWeblog(Weblog)): this.weblog == weblog
    //#post(void setWeblog(Weblog)): init'ed(this.weblog)
    }
    //#WeblogRequest.java:201: end of method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setWeblog(Weblog)
    
    
    /**
     * Get the Locale instance to be used for this request.
     *
     * The Locale is determined via these rules ...
     *   1. if a locale is explicitly specified, then it is used
     *   2. if no locale is specified, then use the weblog default locale
     */
    public Locale getLocaleInstance() {
        
        if(localeInstance == null && locale != null) {
    //#WeblogRequest.java:213: method: Locale org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getLocaleInstance()
    //#WeblogRequest.java:213: Warning: suspicious precondition
    //#    the precondition for this.__Tag is not a contiguous range of values
    //#    severity: SUPPRESSED
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    suspicious precondition index: [10]
    //#    Attribs:  Soft
    //#input(Locale getLocaleInstance()): "Error looking up weblog "._tainted
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogCommentRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogFeedRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogPageRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewResourceRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogResourceRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogSearchRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[org/apache/roller/weblogger/ui/rendering/util/WeblogTrackbackRequest]
    //#input(Locale getLocaleInstance()): __Descendant_Table[others]
    //#input(Locale getLocaleInstance()): __Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): java.lang.Boolean.TRUE
    //#input(Locale getLocaleInstance()): log
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogCommentRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogFeedRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogPageRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewResourceRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogResourceRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogSearchRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): org/apache/roller/weblogger/ui/rendering/util/WeblogTrackbackRequest.__Dispatch_Table.getWeblog()Lorg/apache/roller/weblogger/pojos/Weblog;
    //#input(Locale getLocaleInstance()): this
    //#input(Locale getLocaleInstance()): this.__Tag
    //#input(Locale getLocaleInstance()): this.locale
    //#input(Locale getLocaleInstance()): this.locale._tainted
    //#input(Locale getLocaleInstance()): this.localeInstance
    //#input(Locale getLocaleInstance()): this.weblogHandle
    //#input(Locale getLocaleInstance()): this.weblogHandle._tainted
    //#output(Locale getLocaleInstance()): new Locale(getLocaleInstance#1) num objects
    //#output(Locale getLocaleInstance()): new Locale(getLocaleInstance#2) num objects
    //#output(Locale getLocaleInstance()): return_value
    //#output(Locale getLocaleInstance()): this.localeInstance
    //#output(Locale getLocaleInstance()): this.weblog
    //#new obj(Locale getLocaleInstance()): new Locale(getLocaleInstance#1)
    //#new obj(Locale getLocaleInstance()): new Locale(getLocaleInstance#2)
    //#pre[6] (Locale getLocaleInstance()): init'ed(this.localeInstance)
    //#pre[5] (Locale getLocaleInstance()): (soft) log != null
    //#pre[10] (Locale getLocaleInstance()): (soft) this.__Tag in {org/apache/roller/weblogger/ui/rendering/util/WeblogCommentRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogFeedRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPageRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogPreviewResourceRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogResourceRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogSearchRequest, org/apache/roller/weblogger/ui/rendering/util/WeblogTrackbackRequest}
    //#pre[11] (Locale getLocaleInstance()): (soft) init'ed(this.locale)
    //#pre[13] (Locale getLocaleInstance()): (soft) init'ed(this.weblogHandle)
    //#post(Locale getLocaleInstance()): init'ed(return_value)
    //#post(Locale getLocaleInstance()): this.localeInstance == return_value
    //#post(Locale getLocaleInstance()): possibly_updated(this.weblog)
    //#post(Locale getLocaleInstance()): new Locale(getLocaleInstance#1) num objects == 0
    //#post(Locale getLocaleInstance()): new Locale(getLocaleInstance#2) num objects == 0
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:org.apache.roller.weblogger.business.WebloggerFactory:getWeblogger
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:org.apache.roller.weblogger.business.Weblogger:getUserManager
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:org.apache.roller.weblogger.business.UserManager:getWebsiteByHandle
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:java.lang.Throwable:__curr_excep_obj
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(Locale getLocaleInstance()): Effects-of-calling:org.apache.commons.logging.Log:error
    //#test_vector(Locale getLocaleInstance()): this.localeInstance: Inverse{null}, Addr_Set{null}
    //#test_vector(Locale getLocaleInstance()): this.locale: Addr_Set{null}, Inverse{null}
            String[] langCountry = locale.split("_");
            if(langCountry.length == 1) {
    //#WeblogRequest.java:215: ?use of default init
    //#    init'ed(langCountry.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    basic block: bb_3
    //#    assertion: init'ed(langCountry.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:215: Warning: test always goes same way
    //#    test predetermined because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    from bb: bb_3
    //#    live edge: bb_3-->bb_5
    //#    tested vn: undefined - 1
    //#    tested vn values: {-1}
                localeInstance = new Locale(langCountry[0]);
    //#WeblogRequest.java:216: Warning: dead code
    //#    dead code here because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    dead bb: bb_4
            } else if(langCountry.length == 2) {
    //#WeblogRequest.java:217: ?use of default init
    //#    init'ed(langCountry.length)
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    basic block: bb_5
    //#    assertion: init'ed(langCountry.length)
    //#    VN: undefined
    //#    Expected: {-Inf..+Inf}
    //#    Bad: {Invalid}
    //#    Attribs:  Int  Bad only invalid
    //#WeblogRequest.java:217: Warning: test always goes same way
    //#    test predetermined because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    from bb: bb_5
    //#    live edge: bb_5-->bb_7
    //#    tested vn: undefined - 2
    //#    tested vn values: {-2}
                localeInstance = new Locale(langCountry[0], langCountry[1]);
    //#WeblogRequest.java:218: Warning: dead code
    //#    dead code here because langCountry.length == 0
    //#    severity: LOW
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    dead bb: bb_6
            }
        } else if(localeInstance == null) {
            localeInstance = getWeblog().getLocaleInstance();
    //#WeblogRequest.java:221: ?precondition failure
    //#    org/apache/roller/weblogger/ui/rendering/util/WeblogRequest.getWeblog: init'ed(this.weblog)
    //#    severity: SUPPRESSED
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    basic block: bb_9
    //#    assertion: init'ed(this.weblog)
    //#    callee: Weblog org/apache/roller/weblogger/ui/rendering/util/WeblogRequest.getWeblog()
    //#    callee assertion: init'ed(this.weblog)
    //#    callee file: WeblogRequest.java
    //#    callee precondition index: [5]
    //#    callee srcpos: 187
    //#    VN: this.weblog
    //#    Expected: Univ-VN-Set
    //#    Bad: {Invalid}
    //#    Attribs:  Ptr  Bad only invalid
    //#WeblogRequest.java:221: ?null dereference
    //#    getWeblog(...) != null
    //#    severity: MEDIUM
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    basic block: bb_9
    //#    assertion: getWeblog(...) != null
    //#    VN: getWeblog(...)
    //#    Expected: Inverse{null} or Invalid
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad
    //#WeblogRequest.java:221: Warning: method not available
    //#    -- call on Locale org.apache.roller.weblogger.pojos.Weblog:getLocaleInstance()
    //#    severity: INFORMATIONAL
    //#    class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
    //#    method: Locale getLocaleInstance()
    //#    unanalyzed callee: Locale org.apache.roller.weblogger.pojos.Weblog:getLocaleInstance()
        }
        
        return localeInstance;
    //#WeblogRequest.java:224: end of method: Locale org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.getLocaleInstance()
    }

    public void setLocaleInstance(Locale localeInstance) {
        this.localeInstance = localeInstance;
    //#WeblogRequest.java:228: method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setLocaleInstance(Locale)
    //#input(void setLocaleInstance(Locale)): localeInstance
    //#input(void setLocaleInstance(Locale)): this
    //#output(void setLocaleInstance(Locale)): this.localeInstance
    //#post(void setLocaleInstance(Locale)): this.localeInstance == localeInstance
    //#post(void setLocaleInstance(Locale)): init'ed(this.localeInstance)
    }
    //#WeblogRequest.java:229: end of method: void org.apache.roller.weblogger.ui.rendering.util.WeblogRequest.setLocaleInstance(Locale)
    
}
    //#WeblogRequest.java:: end of class: org.apache.roller.weblogger.ui.rendering.util.WeblogRequest
