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

import com.sun.syndication.feed.atom.Category;
import java.util.ArrayList;
import java.util.List;


/** 
 * Categories object may contain Category objects 
 *//*
	 appInlineCategories =
 element app:categories {
     attribute fixed { "yes" | "no" }?,
     attribute scheme { atomURI }?,
     (atomCategory*)
 }
 */
public class Categories {
    //#Categories.java:35: method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.org.apache.roller.weblogger.webservices.atomprotocol.Categories()
    //#input(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): this
    //#output(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): new ArrayList(Categories#1) num objects
    //#output(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): this.categories
    //#output(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): this.fixed
    //#output(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): this.scheme
    //#new obj(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): new ArrayList(Categories#1)
    //#post(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): this.categories == &new ArrayList(Categories#1)
    //#post(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): this.fixed == 0
    //#post(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): this.scheme == null
    //#post(void org.apache.roller.weblogger.webservices.atomprotocol.Categories()): new ArrayList(Categories#1) num objects == 1
    private List categories = new ArrayList(); // of Category objects
    private String scheme = null;
    private boolean fixed = false;
    //#Categories.java:38: end of method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.org.apache.roller.weblogger.webservices.atomprotocol.Categories()
    
    /** Add category list of those specified*/
    public void addCategory(Category cat) {
        categories.add(cat);
    //#Categories.java:42: method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.addCategory(Category)
    //#input(void addCategory(Category)): cat
    //#input(void addCategory(Category)): this
    //#input(void addCategory(Category)): this.categories
    //#pre[3] (void addCategory(Category)): this.categories != null
    }
    //#Categories.java:43: end of method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.addCategory(Category)
    
    /** Iterate over Category objects */
    public List getCategories() {
        return categories;
    //#Categories.java:47: method: List org.apache.roller.weblogger.webservices.atomprotocol.Categories.getCategories()
    //#input(List getCategories()): this
    //#input(List getCategories()): this.categories
    //#output(List getCategories()): return_value
    //#pre[2] (List getCategories()): init'ed(this.categories)
    //#post(List getCategories()): return_value == this.categories
    //#post(List getCategories()): init'ed(return_value)
    //#Categories.java:47: end of method: List org.apache.roller.weblogger.webservices.atomprotocol.Categories.getCategories()
    }

    /** True if clients MUST use one of the categories specified */
    public boolean isFixed() {
        return fixed;
    //#Categories.java:52: method: bool org.apache.roller.weblogger.webservices.atomprotocol.Categories.isFixed()
    //#input(bool isFixed()): this
    //#input(bool isFixed()): this.fixed
    //#output(bool isFixed()): return_value
    //#pre[2] (bool isFixed()): init'ed(this.fixed)
    //#post(bool isFixed()): return_value == this.fixed
    //#post(bool isFixed()): init'ed(return_value)
    //#Categories.java:52: end of method: bool org.apache.roller.weblogger.webservices.atomprotocol.Categories.isFixed()
    }

    /** True if clients MUST use one of the categories specified */
    public void setFixed(boolean fixed) {
        this.fixed = fixed;
    //#Categories.java:57: method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.setFixed(bool)
    //#input(void setFixed(bool)): fixed
    //#input(void setFixed(bool)): this
    //#output(void setFixed(bool)): this.fixed
    //#post(void setFixed(bool)): this.fixed == fixed
    //#post(void setFixed(bool)): init'ed(this.fixed)
    }
    //#Categories.java:58: end of method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.setFixed(bool)

    /** Category URI scheme to use for Categories without a scheme */
    public String getScheme() {
        return scheme;
    //#Categories.java:62: method: String org.apache.roller.weblogger.webservices.atomprotocol.Categories.getScheme()
    //#input(String getScheme()): this
    //#input(String getScheme()): this.scheme
    //#output(String getScheme()): return_value
    //#pre[2] (String getScheme()): init'ed(this.scheme)
    //#post(String getScheme()): return_value == this.scheme
    //#post(String getScheme()): init'ed(return_value)
    //#Categories.java:62: end of method: String org.apache.roller.weblogger.webservices.atomprotocol.Categories.getScheme()
    }

    /** Category URI scheme to use for Categories without a scheme */
    public void setScheme(String scheme) {
        this.scheme = scheme;
    //#Categories.java:67: method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.setScheme(String)
    //#input(void setScheme(String)): scheme
    //#input(void setScheme(String)): this
    //#output(void setScheme(String)): this.scheme
    //#post(void setScheme(String)): this.scheme == scheme
    //#post(void setScheme(String)): init'ed(this.scheme)
    }
    //#Categories.java:68: end of method: void org.apache.roller.weblogger.webservices.atomprotocol.Categories.setScheme(String)

}
    //#output(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Descendant_Table[org/apache/roller/weblogger/webservices/atomprotocol/Categories]
    //#output(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.addCategory(Lcom/sun/syndication/feed/atom/Category;)V
    //#output(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.getCategories()Ljava/util/List;
    //#output(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.getScheme()Ljava/lang/String;
    //#output(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.isFixed()Z
    //#output(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.setFixed(Z)V
    //#output(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.setScheme(Ljava/lang/String;)V
    //#post(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Descendant_Table[org/apache/roller/weblogger/webservices/atomprotocol/Categories] == &__Dispatch_Table
    //#post(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.addCategory(Lcom/sun/syndication/feed/atom/Category;)V == &addCategory
    //#post(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.getCategories()Ljava/util/List; == &getCategories
    //#post(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.getScheme()Ljava/lang/String; == &getScheme
    //#post(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.isFixed()Z == &isFixed
    //#post(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.setFixed(Z)V == &setFixed
    //#post(org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init): __Dispatch_Table.setScheme(Ljava/lang/String;)V == &setScheme
    //#Categories.java:: end of method: org.apache.roller.weblogger.webservices.atomprotocol.Categories.org.apache.roller.weblogger.webservices.atomprotocol.Categories__static_init
    //#Categories.java:: end of class: org.apache.roller.weblogger.webservices.atomprotocol.Categories
