/* * Copyright 2014 Thiago da Silva Gonzaga <thiagosg@sjrp.unesp.br>. * * Licensed 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. */ package com.example.collections; import com.example.collections.types.PhoneType; import com.mongocom.annotations.Internal; /** * * @author Thiago da Silva Gonzaga <thiagosg@sjrp.unesp.br>. */ @Internal public class Phone { private PhoneType phoneType; private int countryCode; private int areaCode; private int phoneNumber; //if the class has a parameterized constructor, it must have at least a constructor with no parameters. public Phone() { } public Phone(PhoneType phoneType, int countryCode, int areaCode, int phoneNumber) { this.phoneType = phoneType; this.countryCode = countryCode; this.areaCode = areaCode; this.phoneNumber = phoneNumber; } public PhoneType getPhoneType() { return phoneType; } public void setPhoneType(PhoneType phoneType) { this.phoneType = phoneType; } public int getCountryCode() { return countryCode; } public void setCountryCode(int countryCode) { this.countryCode = countryCode; } public int getAreaCode() { return areaCode; } public void setAreaCode(int areaCode) { this.areaCode = areaCode; } public int getPhoneNumber() { return phoneNumber; } public void setPhoneNumber(int phoneNumber) { this.phoneNumber = phoneNumber; } }