001/*
002 * Licensed to the Apache Software Foundation (ASF) under one or more
003 * contributor license agreements.  See the NOTICE file distributed with
004 * this work for additional information regarding copyright ownership.
005 * The ASF licenses this file to You under the Apache License, Version 2.0
006 * (the "License"); you may not use this file except in compliance with
007 * the License.  You may obtain a copy of the License at
008 *
009 *      http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017package org.apache.juneau.examples.core.pojo;
018
019import static org.apache.juneau.commons.utils.Shorts.*;
020
021import java.util.*;
022
023import org.apache.juneau.commons.bean.*;
024
025/**
026 * Complex Pojo class.
027 *
028 */
029public class PojoComplex {
030
031   private final String id;
032   private final Pojo innerPojo;
033   private final Map<String,List<Pojo>> values;
034
035   /**
036    * Constructor.
037    *
038    * @param id The <bc>id</bc> property value.
039    * @param innerPojo The <bc>innerPojo</bc> property value.
040    * @param values The <bc>values</bc> property value.
041    */
042   @BeanCtor
043   public PojoComplex(@Name("id") String id, @Name("innerPojo") Pojo innerPojo, @Name("values") Map<String,List<Pojo>> values) {
044      this.id = id;
045      this.innerPojo = innerPojo;
046      this.values = values;
047   }
048
049   /**
050    * Bean property getter:  <property>id</property>.
051    *
052    * @return The value of the <property>id</property> property on this bean, or <jk>null</jk> if it is not set.
053    */
054   public String getId() { return id; }
055
056   /**
057    * Bean property getter:  <property>innerPojo</property>.
058    *
059    * @return The value of the <property>innerPojo</property> property on this bean, or <jk>null</jk> if it is not set.
060    */
061   public Pojo getInnerPojo() { return innerPojo; }
062
063   /**
064    * Bean property getter:  <property>values</property>.
065    *
066    * @return The value of the <property>values</property> property on this bean, or <jk>null</jk> if it is not set.
067    */
068   public Map<String,List<Pojo>> getValues() { return u(values); }
069}