//# 2 errors, 482 messages
//#
/*
    //#metaweblogapihandler.java:1:1: class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
 * Copyright (c) 2003-2006, Simon Brown
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 *   - Redistributions of source code must retain the above copyright
 *     notice, this list of conditions and the following disclaimer.
 *
 *   - Redistributions in binary form must reproduce the above copyright
 *     notice, this list of conditions and the following disclaimer in
 *     the documentation and/or other materials provided with the
 *     distribution.
 *
 *   - Neither the name of Pebble nor the names of its contributors may
 *     be used to endorse or promote products derived from this software
 *     without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */
package net.sourceforge.pebble.webservice;

import java.io.IOException;
import java.util.Collection;
import java.util.Date;
import java.util.Hashtable;
import java.util.Iterator;
import java.util.Vector;

import net.sourceforge.pebble.PebbleContext;
import net.sourceforge.pebble.domain.Blog;
import net.sourceforge.pebble.domain.BlogEntry;
import net.sourceforge.pebble.domain.BlogService;
import net.sourceforge.pebble.domain.BlogServiceException;
import net.sourceforge.pebble.domain.Category;
import net.sourceforge.pebble.domain.Comment;
import net.sourceforge.pebble.domain.FileManager;
import net.sourceforge.pebble.domain.FileMetaData;
import net.sourceforge.pebble.domain.IllegalFileAccessException;
import net.sourceforge.pebble.domain.Tag;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.xmlrpc.XmlRpcException;

/**
 * A handler for the MetaWeblog API (accessed via XML-RPC).
 *
 * @author    Simon Brown
 */
@SuppressWarnings("unchecked")
public class MetaWeblogAPIHandler extends AbstractAPIHandler {
    //#metaweblogapihandler.java:63: method: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): $assertionsDisabled
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.adaptBlogEntry(Lnet/sourceforge/pebble/domain/BlogEntry;)Ljava/util/Hashtable;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.adaptBlogEntryComment(Lnet/sourceforge/pebble/domain/Comment;)Ljava/util/Hashtable;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.editPost(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/util/Hashtable;Z)Z
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.formatPostId(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getAuthenticationManager()Lorg/acegisecurity/AuthenticationManager;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getBlogWithBlogId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getBlogWithPostId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getCategories(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/util/Hashtable;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getPost(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/util/Hashtable;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getPostId(Ljava/lang/String;)Ljava/lang/String;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getRecentPosts(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;I)Ljava/util/Vector;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.newMediaObject(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/util/Hashtable;)Ljava/util/Hashtable;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.newPost(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/util/Hashtable;Z)Ljava/lang/String;
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.populateEntry(Lnet/sourceforge/pebble/domain/BlogEntry;Ljava/util/Hashtable;Ljava/lang/String;)V
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.setAuthenticationManager(Lorg/acegisecurity/AuthenticationManager;)V
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): log
    //#output(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): net/sourceforge/pebble/webservice/AbstractAPIHandler.__Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): $assertionsDisabled == 0
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler] == &__Dispatch_Table
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): net/sourceforge/pebble/webservice/AbstractAPIHandler.__Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler] == &__Dispatch_Table
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.adaptBlogEntry(Lnet/sourceforge/pebble/domain/BlogEntry;)Ljava/util/Hashtable; == &adaptBlogEntry
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.adaptBlogEntryComment(Lnet/sourceforge/pebble/domain/Comment;)Ljava/util/Hashtable; == &adaptBlogEntryComment
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V == &net/sourceforge/pebble/webservice/AbstractAPIHandler.authenticate
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.editPost(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/util/Hashtable;Z)Z == &editPost
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.formatPostId(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String; == &net/sourceforge/pebble/webservice/AbstractAPIHandler.formatPostId
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getAuthenticationManager()Lorg/acegisecurity/AuthenticationManager; == &net/sourceforge/pebble/webservice/AbstractAPIHandler.getAuthenticationManager
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getBlogWithBlogId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog; == &net/sourceforge/pebble/webservice/AbstractAPIHandler.getBlogWithBlogId
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getBlogWithPostId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog; == &net/sourceforge/pebble/webservice/AbstractAPIHandler.getBlogWithPostId
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getCategories(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/util/Hashtable; == &getCategories
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getPost(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/util/Hashtable; == &getPost
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getPostId(Ljava/lang/String;)Ljava/lang/String; == &net/sourceforge/pebble/webservice/AbstractAPIHandler.getPostId
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.getRecentPosts(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;I)Ljava/util/Vector; == &getRecentPosts
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.newMediaObject(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/util/Hashtable;)Ljava/util/Hashtable; == &newMediaObject
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.newPost(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/util/Hashtable;Z)Ljava/lang/String; == &newPost
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.populateEntry(Lnet/sourceforge/pebble/domain/BlogEntry;Ljava/util/Hashtable;Ljava/lang/String;)V == &populateEntry
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): __Dispatch_Table.setAuthenticationManager(Lorg/acegisecurity/AuthenticationManager;)V == &net/sourceforge/pebble/webservice/AbstractAPIHandler.setAuthenticationManager
    //#post(net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init): init'ed(log)
    //#metaweblogapihandler.java:63: method: void net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.net.sourceforge.pebble.webservice.MetaWeblogAPIHandler()
    //#input(void net.sourceforge.pebble.webservice.MetaWeblogAPIHandler()): this
    //#metaweblogapihandler.java:63: end of method: void net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.net.sourceforge.pebble.webservice.MetaWeblogAPIHandler()

  static final String BODY = "body";
  static final String AUTHOR = "author";
  static final String EMAIL = "email";
  static final String DATE = "date";
  static final String WEBSITE = "website";
  static final String IP_ADDRESS = "ipAddress";
  static final String URL = "url";
  static final String BLOG_ID = "blogid";
  static final String BLOG_NAME = "blogName";
  static final String DATE_CREATED = "dateCreated";
  static final String USER_ID = "userId";
  static final String POST_ID = "postid";
  static final String TITLE = "title";
  static final String DESCRIPTION = "description";
  static final String PERMALINK = "permaLink";
  static final String PUB_DATE = "pubDate";
  static final String CATEGORIES = "categories";
  static final String TAGS = "tags";
  static final String NAME = "name";
  static final String TYPE = "type";
  static final String BITS = "bits";
  static final String HTML_URL = "htmlUrl";
  static final String RSS_URL = "rssUrl";
  static final String COMMENTS = "comments";

  /** the log used by this class */
  private static Log log = LogFactory.getLog(MetaWeblogAPIHandler.class);
    //#metaweblogapihandler.java:91: Warning: method not available
    //#    -- call on Log org.apache.commons.logging.LogFactory:getLog(Class)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init
    //#    unanalyzed callee: Log org.apache.commons.logging.LogFactory:getLog(Class)
    //#metaweblogapihandler.java:91: end of method: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.net.sourceforge.pebble.webservice.MetaWeblogAPIHandler__static_init

  /**
   * Creates a new media object on the server.
   *
   * @param blogid    the ID of the blog
   * @param username  the username used for logging in via XML-RPC
   * @param password  the password used for logging in via XML-RPC
   * @return  a Hashtable (structs) containing information about the object
   * @throws org.apache.xmlrpc.XmlRpcException    if something goes wrong, including an authentication error
   */
  public Hashtable newMediaObject(String blogid, String username, String password, Hashtable struct) throws XmlRpcException {
    log.debug("metaWeblog.newMediaObject(" +
    //#metaweblogapihandler.java:103: method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.newMediaObject(String, String, String, Hashtable)
    //#metaweblogapihandler.java:103: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): __Descendant_Table[others]
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): __Dispatch_Table.getBlogWithBlogId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): blogid
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): log
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): password
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): struct
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): this
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): this.__Tag
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): this.authenticationManager
    //#input(Hashtable newMediaObject(String, String, String, Hashtable)): username
    //#output(Hashtable newMediaObject(String, String, String, Hashtable)): new Hashtable(newMediaObject#4) num objects
    //#output(Hashtable newMediaObject(String, String, String, Hashtable)): return_value
    //#new obj(Hashtable newMediaObject(String, String, String, Hashtable)): new Hashtable(newMediaObject#4)
    //#pre[2] (Hashtable newMediaObject(String, String, String, Hashtable)): log != null
    //#pre[4] (Hashtable newMediaObject(String, String, String, Hashtable)): struct != null
    //#pre[6] (Hashtable newMediaObject(String, String, String, Hashtable)): this.__Tag == net/sourceforge/pebble/webservice/MetaWeblogAPIHandler
    //#pre[7] (Hashtable newMediaObject(String, String, String, Hashtable)): this.authenticationManager != null
    //#presumption(Hashtable newMediaObject(String, String, String, Hashtable)): bytes.length@130 <= 18_889_465_931_478_580_854_783
    //#presumption(Hashtable newMediaObject(String, String, String, Hashtable)): java.util.Hashtable:get(...)@115 != null
    //#presumption(Hashtable newMediaObject(String, String, String, Hashtable)): java.util.Hashtable:get(...)@130 != null
    //#presumption(Hashtable newMediaObject(String, String, String, Hashtable)): net.sourceforge.pebble.domain.FileManager:hasEnoughSpace(...)@132 == 1
    //#presumption(Hashtable newMediaObject(String, String, String, Hashtable)): net.sourceforge.pebble.domain.FileManager:saveFile(...)@133 != null
    //#post(Hashtable newMediaObject(String, String, String, Hashtable)): return_value == &new Hashtable(newMediaObject#4)
    //#post(Hashtable newMediaObject(String, String, String, Hashtable)): new Hashtable(newMediaObject#4) num objects == 1
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:org.apache.xmlrpc.XmlRpcException
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getInstance
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getBlog
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:org.acegisecurity.providers.UsernamePasswordAuthenticationToken
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:org.acegisecurity.AuthenticationManager:authenticate
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:org.acegisecurity.context.SecurityContextHolder:getContext
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:org.acegisecurity.context.SecurityContext:setAuthentication
    //#unanalyzed(Hashtable newMediaObject(String, String, String, Hashtable)): Effects-of-calling:net.sourceforge.pebble.util.SecurityUtils:isUserAuthorisedForBlogAsBlogContributor
    //#test_vector(Hashtable newMediaObject(String, String, String, Hashtable)): java.lang.String:startsWith(...)@117: {0}, {1}
    //#test_vector(Hashtable newMediaObject(String, String, String, Hashtable)): java.lang.String:startsWith(...)@120: {0}, {1}
        blogid + ", " +
        username + ", " +
        "********)");
    log.debug(" name = " + struct.get(NAME));
    //#metaweblogapihandler.java:107: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    log.debug(" type = " + struct.get(TYPE));
    //#metaweblogapihandler.java:108: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)

    Blog blog = getBlogWithBlogId(blogid);
    authenticate(blog, username, password);

    Hashtable ht = new Hashtable();

    String name = (String)struct.get(NAME);
    FileManager manager;
    if (name.startsWith("files/")) {
      manager = new FileManager(blog, FileMetaData.BLOG_FILE);
    //#metaweblogapihandler.java:118: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.FileManager(Blog, String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.FileManager(Blog, String)
      name = name.substring(name.indexOf("/"));
    } else if (name.startsWith("images/")) {
      manager = new FileManager(blog, FileMetaData.BLOG_IMAGE);
    //#metaweblogapihandler.java:121: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.FileManager(Blog, String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.FileManager(Blog, String)
      name = name.substring(name.indexOf("/"));
    } else {
      manager = new FileManager(blog, FileMetaData.BLOG_IMAGE);
    //#metaweblogapihandler.java:124: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.FileManager(Blog, String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.FileManager(Blog, String)
      // name is as specified
    }

    log.debug("Saving to " + name);
    //#metaweblogapihandler.java:128: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    try {
      byte bytes[] = (byte[])struct.get(BITS);
      long itemSize = bytes.length/1024; // number of bytes / 1024
      if (FileManager.hasEnoughSpace(blog, itemSize)) {
    //#metaweblogapihandler.java:132: Warning: method not available
    //#    -- call on bool net.sourceforge.pebble.domain.FileManager:hasEnoughSpace(Blog, double)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: bool net.sourceforge.pebble.domain.FileManager:hasEnoughSpace(Blog, double)
        FileMetaData file = manager.saveFile(name, bytes);
    //#metaweblogapihandler.java:133: Warning: method not available
    //#    -- call on FileMetaData net.sourceforge.pebble.domain.FileManager:saveFile(String, byte[])
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: FileMetaData net.sourceforge.pebble.domain.FileManager:saveFile(String, byte[])
        ht.put(URL, file.getUrl());
    //#metaweblogapihandler.java:134: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.FileMetaData:getUrl()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.FileMetaData:getUrl()
      } else {
        throw new XmlRpcException(0, "You do not have enough free space - please free some space by removing unused files or asking your system administrator to increase your quota from " + PebbleContext.getInstance().getConfiguration().getFileUploadQuota() + " KB.");
    //#metaweblogapihandler.java:136: Warning: method not available
    //#    -- call on PebbleContext net.sourceforge.pebble.PebbleContext:getInstance()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: PebbleContext net.sourceforge.pebble.PebbleContext:getInstance()
    //#metaweblogapihandler.java:136: ?null dereference
    //#    net/sourceforge/pebble/PebbleContext:getInstance(...) != null
    //#    severity: SUPPRESSED
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    basic block: bb_9
    //#    assertion: net/sourceforge/pebble/PebbleContext:getInstance(...) != null
    //#    VN: net.sourceforge.pebble.PebbleContext:getInstance(...)@136
    //#    Expected: Inverse{null} or Invalid
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad  Uncertain
    //#metaweblogapihandler.java:136: Warning: method not available
    //#    -- call on Configuration net.sourceforge.pebble.PebbleContext:getConfiguration()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: Configuration net.sourceforge.pebble.PebbleContext:getConfiguration()
    //#metaweblogapihandler.java:136: ?null dereference
    //#    net/sourceforge/pebble/PebbleContext:getConfiguration(...) != null
    //#    severity: SUPPRESSED
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    basic block: bb_9
    //#    assertion: net/sourceforge/pebble/PebbleContext:getConfiguration(...) != null
    //#    VN: net.sourceforge.pebble.PebbleContext:getConfiguration(...)@136
    //#    Expected: Inverse{null} or Invalid
    //#    Bad: Addr_Set{null}
    //#    Attribs:  Ptr  null in Bad  Uncertain
    //#metaweblogapihandler.java:136: Warning: method not available
    //#    -- call on long net.sourceforge.pebble.Configuration:getFileUploadQuota()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: long net.sourceforge.pebble.Configuration:getFileUploadQuota()
    //#metaweblogapihandler.java:136: Warning: method not available
    //#    -- call on void org.apache.xmlrpc.XmlRpcException(int, String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable newMediaObject(String, String, String, Hashtable)
    //#    unanalyzed callee: void org.apache.xmlrpc.XmlRpcException(int, String)
      }
    } catch (IOException e) {
      e.printStackTrace();
      throw new XmlRpcException(0, "IOException");
    } catch (IllegalFileAccessException e) {
      e.printStackTrace();
      throw new XmlRpcException(0, "Access forbidden");
    }

    return ht;
    //#metaweblogapihandler.java:146: end of method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.newMediaObject(String, String, String, Hashtable)
  }

  /**
   * Gets a list of categories.
   *
   * @param blogid    the ID of the blog (ignored)
   * @param username  the username used for logging in via XML-RPC
   * @param password  the password used for logging in via XML-RPC
   * @return  a Hashtable of Hashtables (a struct of structs) representing categories
   * @throws org.apache.xmlrpc.XmlRpcException    if something goes wrong, including an authentication error
   */
  public Hashtable getCategories(String blogid, String username, String password) throws XmlRpcException {
    log.debug("metaWeblog.getCategories(" +
    //#metaweblogapihandler.java:159: method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.getCategories(String, String, String)
    //#metaweblogapihandler.java:159: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    //#input(Hashtable getCategories(String, String, String)): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#input(Hashtable getCategories(String, String, String)): __Descendant_Table[others]
    //#input(Hashtable getCategories(String, String, String)): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V
    //#input(Hashtable getCategories(String, String, String)): __Dispatch_Table.getBlogWithBlogId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#input(Hashtable getCategories(String, String, String)): blogid
    //#input(Hashtable getCategories(String, String, String)): log
    //#input(Hashtable getCategories(String, String, String)): password
    //#input(Hashtable getCategories(String, String, String)): this
    //#input(Hashtable getCategories(String, String, String)): this.__Tag
    //#input(Hashtable getCategories(String, String, String)): this.authenticationManager
    //#input(Hashtable getCategories(String, String, String)): username
    //#output(Hashtable getCategories(String, String, String)): new Hashtable(getCategories#2) num objects
    //#output(Hashtable getCategories(String, String, String)): return_value
    //#new obj(Hashtable getCategories(String, String, String)): new Hashtable(getCategories#2)
    //#pre[2] (Hashtable getCategories(String, String, String)): log != null
    //#pre[5] (Hashtable getCategories(String, String, String)): this.__Tag == net/sourceforge/pebble/webservice/MetaWeblogAPIHandler
    //#pre[6] (Hashtable getCategories(String, String, String)): this.authenticationManager != null
    //#presumption(Hashtable getCategories(String, String, String)): java.util.Iterator:next(...)@171 != null
    //#presumption(Hashtable getCategories(String, String, String)): net.sourceforge.pebble.domain.Blog:getCategories(...)@168 != null
    //#post(Hashtable getCategories(String, String, String)): return_value == &new Hashtable(getCategories#2)
    //#post(Hashtable getCategories(String, String, String)): new Hashtable(getCategories#2) num objects == 1
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:org.apache.xmlrpc.XmlRpcException
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getInstance
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getBlog
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:org.acegisecurity.providers.UsernamePasswordAuthenticationToken
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:org.acegisecurity.AuthenticationManager:authenticate
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:org.acegisecurity.context.SecurityContextHolder:getContext
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:org.acegisecurity.context.SecurityContext:setAuthentication
    //#unanalyzed(Hashtable getCategories(String, String, String)): Effects-of-calling:net.sourceforge.pebble.util.SecurityUtils:isUserAuthorisedForBlogAsBlogContributor
    //#test_vector(Hashtable getCategories(String, String, String)): java.util.Iterator:hasNext(...)@170: {1}, {0}
    //#test_vector(Hashtable getCategories(String, String, String)): net.sourceforge.pebble.domain.Category:isRootCategory(...)@172: {1}, {0}
        blogid + ", " +
        username + ", " +
        "********)");

    Blog blog = getBlogWithBlogId(blogid);
    authenticate(blog, username, password);

    Hashtable categories = new Hashtable();
    Iterator it = blog.getCategories().iterator();
    //#metaweblogapihandler.java:168: Warning: method not available
    //#    -- call on List net.sourceforge.pebble.domain.Blog:getCategories()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: List net.sourceforge.pebble.domain.Blog:getCategories()
    Category category;
    while (it.hasNext()) {
      category = (Category)it.next();
      if (!category.isRootCategory()) {
    //#metaweblogapihandler.java:172: Warning: method not available
    //#    -- call on bool net.sourceforge.pebble.domain.Category:isRootCategory()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: bool net.sourceforge.pebble.domain.Category:isRootCategory()
        Hashtable struct = new Hashtable();
        struct.put(DESCRIPTION, category.getId());
    //#metaweblogapihandler.java:174: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Category:getId()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Category:getId()
        struct.put(HTML_URL, category.getPermalink());
    //#metaweblogapihandler.java:175: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Category:getPermalink()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Category:getPermalink()
        struct.put(RSS_URL, blog.getUrl() + "rss.xml?category=" + category.getId());
    //#metaweblogapihandler.java:176: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Blog:getUrl()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Blog:getUrl()
    //#metaweblogapihandler.java:176: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Category:getId()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Category:getId()
        categories.put(category.getId(), struct);
    //#metaweblogapihandler.java:177: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Category:getId()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getCategories(String, String, String)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Category:getId()
      }
    }

    return categories;
    //#metaweblogapihandler.java:181: end of method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.getCategories(String, String, String)
  }

  /**
   * Gets a list of the recent blog entries.
   *
   * @param blogid    the ID of the blog (ignored)
   * @param username  the username used for logging in via XML-RPC
   * @param password  the password used for logging in via XML-RPC
   * @param numberOfPosts   the number of posts to get
   * @return  a Vector of Hashtables (an array of structs) representing blog entries
   * @throws org.apache.xmlrpc.XmlRpcException    if something goes wrong, including an authentication error
   */
  public Vector getRecentPosts(String blogid, String username, String password, int numberOfPosts) throws XmlRpcException {
    log.debug("metaWeblog.getRecentPosts(" +
    //#metaweblogapihandler.java:195: method: Vector net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.getRecentPosts(String, String, String, int)
    //#metaweblogapihandler.java:195: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Vector getRecentPosts(String, String, String, int)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    //#input(Vector getRecentPosts(String, String, String, int)): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#input(Vector getRecentPosts(String, String, String, int)): __Descendant_Table[others]
    //#input(Vector getRecentPosts(String, String, String, int)): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V
    //#input(Vector getRecentPosts(String, String, String, int)): __Dispatch_Table.formatPostId(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    //#input(Vector getRecentPosts(String, String, String, int)): __Dispatch_Table.getBlogWithBlogId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#input(Vector getRecentPosts(String, String, String, int)): blogid
    //#input(Vector getRecentPosts(String, String, String, int)): log
    //#input(Vector getRecentPosts(String, String, String, int)): numberOfPosts
    //#input(Vector getRecentPosts(String, String, String, int)): password
    //#input(Vector getRecentPosts(String, String, String, int)): this
    //#input(Vector getRecentPosts(String, String, String, int)): this.__Tag
    //#input(Vector getRecentPosts(String, String, String, int)): this.authenticationManager
    //#input(Vector getRecentPosts(String, String, String, int)): username
    //#output(Vector getRecentPosts(String, String, String, int)): new Vector(getRecentPosts#2) num objects
    //#output(Vector getRecentPosts(String, String, String, int)): return_value
    //#new obj(Vector getRecentPosts(String, String, String, int)): new Vector(getRecentPosts#2)
    //#pre[2] (Vector getRecentPosts(String, String, String, int)): log != null
    //#pre[6] (Vector getRecentPosts(String, String, String, int)): this.__Tag == net/sourceforge/pebble/webservice/MetaWeblogAPIHandler
    //#pre[7] (Vector getRecentPosts(String, String, String, int)): this.authenticationManager != null
    //#presumption(Vector getRecentPosts(String, String, String, int)): java.util.Iterator:next(...)@209 != null
    //#presumption(Vector getRecentPosts(String, String, String, int)): net.sourceforge.pebble.domain.Blog:getRecentBlogEntries(...)@204 != null
    //#post(Vector getRecentPosts(String, String, String, int)): return_value == &new Vector(getRecentPosts#2)
    //#post(Vector getRecentPosts(String, String, String, int)): new Vector(getRecentPosts#2) num objects == 1
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getBlog
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.Hashtable
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getBody
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.Hashtable:put
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getAuthor
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getEmail
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getDate
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getPermalink
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getWebsite
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getIpAddress
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getTitle
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getPermalink
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getBody
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getDate
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getAuthor
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Blog:getId
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getId
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:formatPostId
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.Vector
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getCategories
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.Set:iterator
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.Iterator:hasNext
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.Iterator:next
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Category:getId
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.Vector:add
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getAllTags
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.util.List:iterator
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.Tag:getName
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getComments
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:org.apache.xmlrpc.XmlRpcException
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getInstance
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getBlog
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:org.acegisecurity.providers.UsernamePasswordAuthenticationToken
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:org.acegisecurity.AuthenticationManager:authenticate
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:org.acegisecurity.context.SecurityContextHolder:getContext
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:org.acegisecurity.context.SecurityContext:setAuthentication
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:net.sourceforge.pebble.util.SecurityUtils:isUserAuthorisedForBlogAsBlogContributor
    //#unanalyzed(Vector getRecentPosts(String, String, String, int)): Effects-of-calling:java.lang.String:valueOf
    //#test_vector(Vector getRecentPosts(String, String, String, int)): java.util.Iterator:hasNext(...)@208: {1}, {0}
        blogid + ", " +
        username + ", " +
        "********)");

    Blog blog = getBlogWithBlogId(blogid);
    authenticate(blog, username, password);

    Vector posts = new Vector();
    Collection coll = blog.getRecentBlogEntries(numberOfPosts);
    //#metaweblogapihandler.java:204: Warning: method not available
    //#    -- call on List net.sourceforge.pebble.domain.Blog:getRecentBlogEntries(int)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Vector getRecentPosts(String, String, String, int)
    //#    unanalyzed callee: List net.sourceforge.pebble.domain.Blog:getRecentBlogEntries(int)

    Iterator it = coll.iterator();
    BlogEntry entry;
    while (it.hasNext()) {
      entry = (BlogEntry)it.next();
      posts.add(adaptBlogEntry(entry));
    }

    return posts;
    //#metaweblogapihandler.java:213: end of method: Vector net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.getRecentPosts(String, String, String, int)
  }

  /**
   * Gets an individual blog entry.
   *
   * @param postid    the ID of the blog (ignored)
   * @param username  the username used for logging in via XML-RPC
   * @param password  the password used for logging in via XML-RPC
   * @return  a Hashtable representing a blog entry
   * @throws org.apache.xmlrpc.XmlRpcException    if something goes wrong, including an authentication error
   */
  public Hashtable getPost(String postid, String username, String password) throws XmlRpcException {
    log.debug("metaWeblog.getPost(" +
    //#metaweblogapihandler.java:226: method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.getPost(String, String, String)
    //#metaweblogapihandler.java:226: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getPost(String, String, String)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    //#input(Hashtable getPost(String, String, String)): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#input(Hashtable getPost(String, String, String)): __Descendant_Table[others]
    //#input(Hashtable getPost(String, String, String)): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V
    //#input(Hashtable getPost(String, String, String)): __Dispatch_Table.formatPostId(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    //#input(Hashtable getPost(String, String, String)): __Dispatch_Table.getBlogWithPostId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#input(Hashtable getPost(String, String, String)): __Dispatch_Table.getPostId(Ljava/lang/String;)Ljava/lang/String;
    //#input(Hashtable getPost(String, String, String)): log
    //#input(Hashtable getPost(String, String, String)): password
    //#input(Hashtable getPost(String, String, String)): postid
    //#input(Hashtable getPost(String, String, String)): this
    //#input(Hashtable getPost(String, String, String)): this.__Tag
    //#input(Hashtable getPost(String, String, String)): this.authenticationManager
    //#input(Hashtable getPost(String, String, String)): username
    //#output(Hashtable getPost(String, String, String)): new Hashtable(adaptBlogEntry#1) num objects
    //#output(Hashtable getPost(String, String, String)): return_value
    //#new obj(Hashtable getPost(String, String, String)): new Hashtable(adaptBlogEntry#1)
    //#pre[1] (Hashtable getPost(String, String, String)): log != null
    //#pre[3] (Hashtable getPost(String, String, String)): postid != null
    //#pre[5] (Hashtable getPost(String, String, String)): this.__Tag == net/sourceforge/pebble/webservice/MetaWeblogAPIHandler
    //#pre[6] (Hashtable getPost(String, String, String)): this.authenticationManager != null
    //#presumption(Hashtable getPost(String, String, String)): net.sourceforge.pebble.domain.BlogService:getBlogEntry(...)@237 != null
    //#post(Hashtable getPost(String, String, String)): return_value == &new Hashtable(adaptBlogEntry#1)
    //#post(Hashtable getPost(String, String, String)): new Hashtable(adaptBlogEntry#1) num objects == 1
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getBlog
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.Hashtable
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getBody
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.Hashtable:put
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getAuthor
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getEmail
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getDate
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getPermalink
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getWebsite
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getIpAddress
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getTitle
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getPermalink
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getBody
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getDate
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getAuthor
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Blog:getId
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getId
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:formatPostId
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.Vector
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getCategories
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.Set:iterator
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.Iterator:hasNext
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.Iterator:next
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Category:getId
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.Vector:add
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getAllTags
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.util.List:iterator
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.Tag:getName
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getComments
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:org.apache.xmlrpc.XmlRpcException
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.lang.String:lastIndexOf
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.lang.String:substring
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getInstance
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getBlog
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:org.acegisecurity.providers.UsernamePasswordAuthenticationToken
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:org.acegisecurity.AuthenticationManager:authenticate
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:org.acegisecurity.context.SecurityContextHolder:getContext
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:org.acegisecurity.context.SecurityContext:setAuthentication
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:net.sourceforge.pebble.util.SecurityUtils:isUserAuthorisedForBlogAsBlogContributor
    //#unanalyzed(Hashtable getPost(String, String, String)): Effects-of-calling:java.lang.String:valueOf
        postid + ", " +
        username + ", " +
        "********)");

    Blog blog = getBlogWithPostId(postid);
    postid = getPostId(postid);
    authenticate(blog, username, password);
    BlogService service = new BlogService();
    //#metaweblogapihandler.java:234: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogService()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getPost(String, String, String)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogService()
    BlogEntry entry = null;
    //#metaweblogapihandler.java:235: Warning: unused assignment
    //#    unused assignment into entry
    //#    severity: SUPPRESSED
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getPost(String, String, String)
    //#    Attribs:  Uncertain
    try {
      entry = service.getBlogEntry(blog, postid);
    //#metaweblogapihandler.java:237: Warning: method not available
    //#    -- call on BlogEntry net.sourceforge.pebble.domain.BlogService:getBlogEntry(Blog, String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable getPost(String, String, String)
    //#    unanalyzed callee: BlogEntry net.sourceforge.pebble.domain.BlogService:getBlogEntry(Blog, String)
    } catch (BlogServiceException e) {
      throw new XmlRpcException(0, "Blog entry with ID of " + postid + " could not be loaded");
    }

    if (entry != null) {
      return adaptBlogEntry(entry);
    } else {
      throw new XmlRpcException(0, "Blog entry with ID of " + postid + " was not found.");
    //#metaweblogapihandler.java:245: end of method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.getPost(String, String, String)
    }
  }

  /**
   * Creates a new blog entry.
   *
   * @param blogid    the ID of the blog (ignored)
   * @param username  the username used for logging in via XML-RPC
   * @param password  the password used for logging in via XML-RPC
   * @param struct    the struct containing the new blog entry
   * @param publish   a flag to indicate whether the entry should be published
   * @return  a String representing the ID of the new blog entry
   * @throws org.apache.xmlrpc.XmlRpcException    if something goes wrong, including an authentication error
   */
  public String newPost(String blogid, String username, String password, Hashtable struct, boolean publish) throws XmlRpcException {
    log.debug("metaWeblog.newPost(" +
    //#metaweblogapihandler.java:261: method: String net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.newPost(String, String, String, Hashtable, bool)
    //#metaweblogapihandler.java:261: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: String newPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    //#input(String newPost(String, String, String, Hashtable, bool)): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#input(String newPost(String, String, String, Hashtable, bool)): __Descendant_Table[others]
    //#input(String newPost(String, String, String, Hashtable, bool)): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V
    //#input(String newPost(String, String, String, Hashtable, bool)): __Dispatch_Table.formatPostId(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    //#input(String newPost(String, String, String, Hashtable, bool)): __Dispatch_Table.getBlogWithBlogId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#input(String newPost(String, String, String, Hashtable, bool)): blogid
    //#input(String newPost(String, String, String, Hashtable, bool)): log
    //#input(String newPost(String, String, String, Hashtable, bool)): password
    //#input(String newPost(String, String, String, Hashtable, bool)): publish
    //#input(String newPost(String, String, String, Hashtable, bool)): struct
    //#input(String newPost(String, String, String, Hashtable, bool)): this
    //#input(String newPost(String, String, String, Hashtable, bool)): this.__Tag
    //#input(String newPost(String, String, String, Hashtable, bool)): this.authenticationManager
    //#input(String newPost(String, String, String, Hashtable, bool)): username
    //#output(String newPost(String, String, String, Hashtable, bool)): return_value
    //#pre[2] (String newPost(String, String, String, Hashtable, bool)): log != null
    //#pre[5] (String newPost(String, String, String, Hashtable, bool)): struct != null
    //#pre[7] (String newPost(String, String, String, Hashtable, bool)): this.__Tag == net/sourceforge/pebble/webservice/MetaWeblogAPIHandler
    //#pre[8] (String newPost(String, String, String, Hashtable, bool)): this.authenticationManager != null
    //#post(String newPost(String, String, String, Hashtable, bool)): return_value != null
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.util.Hashtable:get
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setTitle
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setBody
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setAuthor
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.util.Vector:size
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getBlog
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.util.Vector:get
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.Blog:getCategory
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:addCategory
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setTags
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.apache.xmlrpc.XmlRpcException
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getInstance
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getBlog
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.providers.UsernamePasswordAuthenticationToken
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.AuthenticationManager:authenticate
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.context.SecurityContextHolder:getContext
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.context.SecurityContext:setAuthentication
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.util.SecurityUtils:isUserAuthorisedForBlogAsBlogContributor
    //#unanalyzed(String newPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.String:valueOf
    //#test_vector(String newPost(String, String, String, Hashtable, bool)): java.util.Hashtable:containsKey(...)@274: {0}, {1}
        blogid + ", " +
        username + ", " +
        "********, " +
        struct + ", " +
        publish + ")");

    try {
      Blog blog = getBlogWithBlogId(blogid);
      authenticate(blog, username, password);

      BlogEntry entry = new BlogEntry(blog);
    //#metaweblogapihandler.java:272: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry(Blog)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: String newPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry(Blog)

      if (struct.containsKey(PUB_DATE)) {
        Date date = (Date)struct.get(PUB_DATE);
        entry.setDate(date);
    //#metaweblogapihandler.java:276: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:setDate(Date)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: String newPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:setDate(Date)
      }

      populateEntry(entry, struct, username);
      entry.setPublished(publish);
    //#metaweblogapihandler.java:280: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:setPublished(bool)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: String newPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:setPublished(bool)

      BlogService service = new BlogService();
    //#metaweblogapihandler.java:282: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogService()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: String newPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogService()
      service.putBlogEntry(entry);
    //#metaweblogapihandler.java:283: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogService:putBlogEntry(BlogEntry)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: String newPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogService:putBlogEntry(BlogEntry)

      return formatPostId(blogid, entry.getId());
    //#metaweblogapihandler.java:285: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.BlogEntry:getId()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: String newPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.BlogEntry:getId()
    } catch (BlogServiceException be) {
      throw new XmlRpcException(0, be.getMessage());
    //#metaweblogapihandler.java:287: end of method: String net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.newPost(String, String, String, Hashtable, bool)
    }
  }

  /**
   * Edits an existing blog entry.
   *
   * @param postid    the ID of the blog entry to be edited
   * @param username  the username used for logging in via XML-RPC
   * @param password  the password used for logging in via XML-RPC
   * @param struct    the new content of the new blog entry
   * @param publish   a flag to indicate whether the entry should be published
   * @return  a boolean true value to signal success
   * @throws org.apache.xmlrpc.XmlRpcException    if something goes wrong, including an authentication error
   */
  public boolean editPost(String postid, String username, String password, Hashtable struct, boolean publish) throws XmlRpcException {
    log.debug("BloggerAPI.editPost(" +
    //#metaweblogapihandler.java:303: method: bool net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.editPost(String, String, String, Hashtable, bool)
    //#metaweblogapihandler.java:303: Warning: method not available
    //#    -- call on void org.apache.commons.logging.Log:debug(Object)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: bool editPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void org.apache.commons.logging.Log:debug(Object)
    //#input(bool editPost(String, String, String, Hashtable, bool)): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#input(bool editPost(String, String, String, Hashtable, bool)): __Descendant_Table[others]
    //#input(bool editPost(String, String, String, Hashtable, bool)): __Dispatch_Table.authenticate(Lnet/sourceforge/pebble/domain/Blog;Ljava/lang/String;Ljava/lang/String;)V
    //#input(bool editPost(String, String, String, Hashtable, bool)): __Dispatch_Table.getBlogWithPostId(Ljava/lang/String;)Lnet/sourceforge/pebble/domain/Blog;
    //#input(bool editPost(String, String, String, Hashtable, bool)): __Dispatch_Table.getPostId(Ljava/lang/String;)Ljava/lang/String;
    //#input(bool editPost(String, String, String, Hashtable, bool)): log
    //#input(bool editPost(String, String, String, Hashtable, bool)): password
    //#input(bool editPost(String, String, String, Hashtable, bool)): postid
    //#input(bool editPost(String, String, String, Hashtable, bool)): publish
    //#input(bool editPost(String, String, String, Hashtable, bool)): struct
    //#input(bool editPost(String, String, String, Hashtable, bool)): this
    //#input(bool editPost(String, String, String, Hashtable, bool)): this.__Tag
    //#input(bool editPost(String, String, String, Hashtable, bool)): this.authenticationManager
    //#input(bool editPost(String, String, String, Hashtable, bool)): username
    //#output(bool editPost(String, String, String, Hashtable, bool)): return_value
    //#pre[1] (bool editPost(String, String, String, Hashtable, bool)): log != null
    //#pre[3] (bool editPost(String, String, String, Hashtable, bool)): postid != null
    //#pre[5] (bool editPost(String, String, String, Hashtable, bool)): struct != null
    //#pre[7] (bool editPost(String, String, String, Hashtable, bool)): this.__Tag == net/sourceforge/pebble/webservice/MetaWeblogAPIHandler
    //#pre[8] (bool editPost(String, String, String, Hashtable, bool)): this.authenticationManager != null
    //#presumption(bool editPost(String, String, String, Hashtable, bool)): net.sourceforge.pebble.domain.BlogService:getBlogEntry(...)@315 != null
    //#post(bool editPost(String, String, String, Hashtable, bool)): return_value == 1
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.util.Hashtable:get
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setTitle
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setBody
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setAuthor
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.util.Vector:size
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:getBlog
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.util.Vector:get
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.Blog:getCategory
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:addCategory
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogEntry:setTags
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.apache.xmlrpc.XmlRpcException
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.String:lastIndexOf
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:java.lang.String:substring
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getInstance
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.domain.BlogManager:getBlog
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.providers.UsernamePasswordAuthenticationToken
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.AuthenticationManager:authenticate
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.context.SecurityContextHolder:getContext
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:org.acegisecurity.context.SecurityContext:setAuthentication
    //#unanalyzed(bool editPost(String, String, String, Hashtable, bool)): Effects-of-calling:net.sourceforge.pebble.util.SecurityUtils:isUserAuthorisedForBlogAsBlogContributor
        postid + ", " +
        username + ", " +
        "********, " +
        struct + ", " +
        publish + ")");

    try {
      Blog blog = getBlogWithPostId(postid);
      postid = getPostId(postid);
      authenticate(blog, username, password);
      BlogService service = new BlogService();
    //#metaweblogapihandler.java:314: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogService()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: bool editPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogService()
      BlogEntry entry = service.getBlogEntry(blog, postid);
    //#metaweblogapihandler.java:315: Warning: method not available
    //#    -- call on BlogEntry net.sourceforge.pebble.domain.BlogService:getBlogEntry(Blog, String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: bool editPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: BlogEntry net.sourceforge.pebble.domain.BlogService:getBlogEntry(Blog, String)

      if (entry != null) {
        populateEntry(entry, struct, username);
        entry.setPublished(publish);
    //#metaweblogapihandler.java:319: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:setPublished(bool)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: bool editPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:setPublished(bool)

        service.putBlogEntry(entry);
    //#metaweblogapihandler.java:321: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogService:putBlogEntry(BlogEntry)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: bool editPost(String, String, String, Hashtable, bool)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogService:putBlogEntry(BlogEntry)
      } else {
        throw new XmlRpcException(0, "Blog entry with ID of " + postid + " was not found.");
      }

      return true;
    } catch (BlogServiceException be) {
      throw new XmlRpcException(0, be.getMessage());
    //#metaweblogapihandler.java:328: end of method: bool net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.editPost(String, String, String, Hashtable, bool)
    }
  }

  /**
   * Helper method to adapt a blog entry into an XML-RPC compatible struct.
   *
   * @param entry   the BlogEntry to adapt
   * @return  a Hashtable representing the major properties of the entry
   */
  private Hashtable adaptBlogEntry(BlogEntry entry) {
    Hashtable post = new Hashtable();
    //#metaweblogapihandler.java:339: method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.adaptBlogEntry(BlogEntry)
    //#input(Hashtable adaptBlogEntry(BlogEntry)): __Descendant_Table[net/sourceforge/pebble/webservice/MetaWeblogAPIHandler]
    //#input(Hashtable adaptBlogEntry(BlogEntry)): __Descendant_Table[others]
    //#input(Hashtable adaptBlogEntry(BlogEntry)): __Dispatch_Table.formatPostId(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    //#input(Hashtable adaptBlogEntry(BlogEntry)): entry
    //#input(Hashtable adaptBlogEntry(BlogEntry)): this
    //#input(Hashtable adaptBlogEntry(BlogEntry)): this.__Tag
    //#output(Hashtable adaptBlogEntry(BlogEntry)): new Hashtable(adaptBlogEntry#1) num objects
    //#output(Hashtable adaptBlogEntry(BlogEntry)): return_value
    //#new obj(Hashtable adaptBlogEntry(BlogEntry)): new Hashtable(adaptBlogEntry#1)
    //#pre[1] (Hashtable adaptBlogEntry(BlogEntry)): entry != null
    //#pre[3] (Hashtable adaptBlogEntry(BlogEntry)): this.__Tag == net/sourceforge/pebble/webservice/MetaWeblogAPIHandler
    //#presumption(Hashtable adaptBlogEntry(BlogEntry)): java.util.Iterator:next(...)@352 != null
    //#presumption(Hashtable adaptBlogEntry(BlogEntry)): java.util.Iterator:next(...)@359 != null
    //#presumption(Hashtable adaptBlogEntry(BlogEntry)): java.util.Iterator:next(...)@366 != null
    //#presumption(Hashtable adaptBlogEntry(BlogEntry)): net.sourceforge.pebble.domain.BlogEntry:getAllTags(...)@359 != null
    //#presumption(Hashtable adaptBlogEntry(BlogEntry)): net.sourceforge.pebble.domain.BlogEntry:getBlog(...)@347 != null
    //#presumption(Hashtable adaptBlogEntry(BlogEntry)): net.sourceforge.pebble.domain.BlogEntry:getCategories(...)@350 != null
    //#presumption(Hashtable adaptBlogEntry(BlogEntry)): net.sourceforge.pebble.domain.BlogEntry:getComments(...)@366 != null
    //#post(Hashtable adaptBlogEntry(BlogEntry)): return_value == &new Hashtable(adaptBlogEntry#1)
    //#post(Hashtable adaptBlogEntry(BlogEntry)): new Hashtable(adaptBlogEntry#1) num objects == 1
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:java.util.Hashtable
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getBody
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:java.util.Hashtable:put
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getAuthor
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getEmail
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getDate
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getPermalink
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getWebsite
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:net.sourceforge.pebble.domain.Comment:getIpAddress
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:java.lang.StringBuilder
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:java.lang.StringBuilder:append
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:java.lang.StringBuilder:toString
    //#unanalyzed(Hashtable adaptBlogEntry(BlogEntry)): Effects-of-calling:java.lang.String:valueOf
    //#test_vector(Hashtable adaptBlogEntry(BlogEntry)): java.util.Iterator:hasNext(...)@351: {1}, {0}
    //#test_vector(Hashtable adaptBlogEntry(BlogEntry)): java.util.Iterator:hasNext(...)@359: {1}, {0}
    //#test_vector(Hashtable adaptBlogEntry(BlogEntry)): java.util.Iterator:hasNext(...)@366: {1}, {0}
    post.put(TITLE, entry.getTitle());
    //#metaweblogapihandler.java:340: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.BlogEntry:getTitle()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.BlogEntry:getTitle()
    post.put(PERMALINK, entry.getPermalink());
    //#metaweblogapihandler.java:341: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.BlogEntry:getPermalink()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.BlogEntry:getPermalink()
    post.put(TITLE, entry.getTitle());
    //#metaweblogapihandler.java:342: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.BlogEntry:getTitle()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.BlogEntry:getTitle()
    post.put(DESCRIPTION, entry.getBody());
    //#metaweblogapihandler.java:343: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.BlogEntry:getBody()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.BlogEntry:getBody()
    post.put(DATE_CREATED, entry.getDate());
    //#metaweblogapihandler.java:344: Warning: method not available
    //#    -- call on Date net.sourceforge.pebble.domain.BlogEntry:getDate()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: Date net.sourceforge.pebble.domain.BlogEntry:getDate()
    post.put(PUB_DATE, entry.getDate());
    //#metaweblogapihandler.java:345: Warning: method not available
    //#    -- call on Date net.sourceforge.pebble.domain.BlogEntry:getDate()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: Date net.sourceforge.pebble.domain.BlogEntry:getDate()
    post.put(USER_ID, entry.getAuthor());
    //#metaweblogapihandler.java:346: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.BlogEntry:getAuthor()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.BlogEntry:getAuthor()
    post.put(POST_ID, formatPostId(entry.getBlog().getId(), entry.getId()));
    //#metaweblogapihandler.java:347: Warning: method not available
    //#    -- call on Blog net.sourceforge.pebble.domain.BlogEntry:getBlog()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: Blog net.sourceforge.pebble.domain.BlogEntry:getBlog()
    //#metaweblogapihandler.java:347: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Blog:getId()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Blog:getId()
    //#metaweblogapihandler.java:347: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.BlogEntry:getId()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.BlogEntry:getId()

    Vector categories = new Vector();
    Iterator it = entry.getCategories().iterator();
    //#metaweblogapihandler.java:350: Warning: method not available
    //#    -- call on Set net.sourceforge.pebble.domain.BlogEntry:getCategories()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: Set net.sourceforge.pebble.domain.BlogEntry:getCategories()
    while (it.hasNext()) {
      Category cat = (Category)it.next();
      categories.add(cat.getId());
    //#metaweblogapihandler.java:353: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Category:getId()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Category:getId()
    }
    post.put(CATEGORIES, categories);

    //Get Tags
    Vector tags = new Vector();
    for (Tag tag : entry.getAllTags()) {
    //#metaweblogapihandler.java:359: Warning: method not available
    //#    -- call on List net.sourceforge.pebble.domain.BlogEntry:getAllTags()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: List net.sourceforge.pebble.domain.BlogEntry:getAllTags()
        tags.add(tag.getName());
    //#metaweblogapihandler.java:360: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Tag:getName()
    //#    severity: SUPPRESSED
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Tag:getName()
    }
    post.put(TAGS, tags);

    //Get comments
    Vector comments = new Vector();
    for (Comment comment : entry.getComments()) {
    //#metaweblogapihandler.java:366: Warning: method not available
    //#    -- call on List net.sourceforge.pebble.domain.BlogEntry:getComments()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntry(BlogEntry)
    //#    unanalyzed callee: List net.sourceforge.pebble.domain.BlogEntry:getComments()
        comments.add(adaptBlogEntryComment(comment));
    }
    post.put(COMMENTS, comments);

    return post;
    //#metaweblogapihandler.java:371: end of method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.adaptBlogEntry(BlogEntry)
  }

  /** 
   * help method to adapt a blog entry comments into an XML-RPC compatible struct.
   * 
   * @param entry   the BlogEntry to adapt
   * @return  a Hashtable representing the major properties of the entry
   */
  private Hashtable adaptBlogEntryComment(Comment comment) {
      Hashtable cmnt = new Hashtable();
    //#metaweblogapihandler.java:381: method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.adaptBlogEntryComment(Comment)
    //#input(Hashtable adaptBlogEntryComment(Comment)): comment
    //#output(Hashtable adaptBlogEntryComment(Comment)): new Hashtable(adaptBlogEntryComment#1) num objects
    //#output(Hashtable adaptBlogEntryComment(Comment)): return_value
    //#new obj(Hashtable adaptBlogEntryComment(Comment)): new Hashtable(adaptBlogEntryComment#1)
    //#pre[1] (Hashtable adaptBlogEntryComment(Comment)): comment != null
    //#post(Hashtable adaptBlogEntryComment(Comment)): return_value == &new Hashtable(adaptBlogEntryComment#1)
    //#post(Hashtable adaptBlogEntryComment(Comment)): new Hashtable(adaptBlogEntryComment#1) num objects == 1
    //#test_vector(Hashtable adaptBlogEntryComment(Comment)): net.sourceforge.pebble.domain.Comment:getEmail(...)@385: Addr_Set{null}, Inverse{null}
    //#test_vector(Hashtable adaptBlogEntryComment(Comment)): net.sourceforge.pebble.domain.Comment:getWebsite(...)@389: Addr_Set{null}, Inverse{null}
        
      cmnt.put(BODY, comment.getBody());
    //#metaweblogapihandler.java:383: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Comment:getBody()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntryComment(Comment)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Comment:getBody()
      cmnt.put(AUTHOR, comment.getAuthor());
    //#metaweblogapihandler.java:384: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Comment:getAuthor()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntryComment(Comment)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Comment:getAuthor()
      String email = comment.getEmail();
    //#metaweblogapihandler.java:385: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Comment:getEmail()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntryComment(Comment)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Comment:getEmail()
      if (email != null) cmnt.put(EMAIL, email);
      cmnt.put(DATE, comment.getDate());
    //#metaweblogapihandler.java:387: Warning: method not available
    //#    -- call on Date net.sourceforge.pebble.domain.Comment:getDate()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntryComment(Comment)
    //#    unanalyzed callee: Date net.sourceforge.pebble.domain.Comment:getDate()
      cmnt.put(PERMALINK, comment.getPermalink());
    //#metaweblogapihandler.java:388: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Comment:getPermalink()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntryComment(Comment)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Comment:getPermalink()
      String website = comment.getWebsite();
    //#metaweblogapihandler.java:389: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Comment:getWebsite()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntryComment(Comment)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Comment:getWebsite()
      if (website != null) cmnt.put(WEBSITE, website);
      cmnt.put(IP_ADDRESS, comment.getIpAddress());
    //#metaweblogapihandler.java:391: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.Comment:getIpAddress()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: Hashtable adaptBlogEntryComment(Comment)
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.Comment:getIpAddress()

      return cmnt;
    //#metaweblogapihandler.java:393: end of method: Hashtable net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.adaptBlogEntryComment(Comment)
  }

  /**
   * Populates a given BlogEntry.
   *
   * @param entry     the BlogEntry to populate
   * @param struct    a Hashtable containing the blog entry details
   * @param username  the author
   */
  private void populateEntry(BlogEntry entry, Hashtable struct, String username) {
      assert entry != null;
    //#metaweblogapihandler.java:404: method: void net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.populateEntry(BlogEntry, Hashtable, String)
    //#input(void populateEntry(BlogEntry, Hashtable, String)): entry
    //#input(void populateEntry(BlogEntry, Hashtable, String)): struct
    //#input(void populateEntry(BlogEntry, Hashtable, String)): username
    //#pre[1] (void populateEntry(BlogEntry, Hashtable, String)): entry != null
    //#pre[2] (void populateEntry(BlogEntry, Hashtable, String)): struct != null
    //#presumption(void populateEntry(BlogEntry, Hashtable, String)): net.sourceforge.pebble.domain.BlogEntry:getBlog(...)@412 != null
    //#test_vector(void populateEntry(BlogEntry, Hashtable, String)): java.util.Hashtable:get(...)@409: Addr_Set{null}, Inverse{null}
    //#test_vector(void populateEntry(BlogEntry, Hashtable, String)): net.sourceforge.pebble.domain.Blog:getCategory(...)@412: Addr_Set{null}, Inverse{null}
      entry.setTitle((String)struct.get(TITLE));
    //#metaweblogapihandler.java:405: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:setTitle(String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: void populateEntry(BlogEntry, Hashtable, String)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:setTitle(String)
      entry.setBody((String)struct.get(DESCRIPTION));
    //#metaweblogapihandler.java:406: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:setBody(String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: void populateEntry(BlogEntry, Hashtable, String)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:setBody(String)
      entry.setAuthor(username);
    //#metaweblogapihandler.java:407: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:setAuthor(String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: void populateEntry(BlogEntry, Hashtable, String)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:setAuthor(String)

      Vector categories = (Vector)struct.get(CATEGORIES);
      if (categories != null) {
          for (int i = 0; i < categories.size(); i++) {
              Category c = entry.getBlog().getCategory((String)categories.get(i));
    //#metaweblogapihandler.java:412: Warning: method not available
    //#    -- call on Blog net.sourceforge.pebble.domain.BlogEntry:getBlog()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: void populateEntry(BlogEntry, Hashtable, String)
    //#    unanalyzed callee: Blog net.sourceforge.pebble.domain.BlogEntry:getBlog()
    //#metaweblogapihandler.java:412: Warning: method not available
    //#    -- call on Category net.sourceforge.pebble.domain.Blog:getCategory(String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: void populateEntry(BlogEntry, Hashtable, String)
    //#    unanalyzed callee: Category net.sourceforge.pebble.domain.Blog:getCategory(String)
              if (c != null)
                  entry.addCategory(c);
    //#metaweblogapihandler.java:414: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:addCategory(Category)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: void populateEntry(BlogEntry, Hashtable, String)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:addCategory(Category)
          }
      }

      String taglist = (String)struct.get(TAGS);
      entry.setTags( taglist );
    //#metaweblogapihandler.java:419: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.domain.BlogEntry:setTags(String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
    //#    method: void populateEntry(BlogEntry, Hashtable, String)
    //#    unanalyzed callee: void net.sourceforge.pebble.domain.BlogEntry:setTags(String)
  }
    //#metaweblogapihandler.java:420: end of method: void net.sourceforge.pebble.webservice.MetaWeblogAPIHandler.populateEntry(BlogEntry, Hashtable, String)

}
    //#metaweblogapihandler.java:: end of class: net.sourceforge.pebble.webservice.MetaWeblogAPIHandler
