001 /*
002 * Copyright 2005-2007 The Kuali Foundation
003 *
004 *
005 * Licensed under the Educational Community License, Version 2.0 (the "License");
006 * you may not use this file except in compliance with the License.
007 * You may obtain a copy of the License at
008 *
009 * http://www.opensource.org/licenses/ecl2.php
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 */
017 package mocks;
018
019 import java.io.Serializable;
020
021 public class MockOrganization implements Serializable {
022
023 private static final long serialVersionUID = 295309153521813643L;
024
025 private String finCoaCd;
026 private String orgCd;
027 private String reportsToChart;
028 private String reportsToOrg;
029
030 public MockOrganization(String finCoaCd, String orgCd, String reportsToChart, String reportsToOrg) {
031 this.finCoaCd = finCoaCd;
032 this.orgCd = orgCd;
033 this.reportsToChart = reportsToChart;
034 this.reportsToOrg = reportsToOrg;
035 }
036
037 public String getFinCoaCd() {
038 return finCoaCd;
039 }
040 public void setFinCoaCd(String chart) {
041 this.finCoaCd = chart;
042 }
043 public String getOrgCd() {
044 return orgCd;
045 }
046 public void setOrgCd(String org) {
047 this.orgCd = org;
048 }
049 public String getReportsToChart() {
050 return reportsToChart;
051 }
052 public void setReportsToChart(String reportsToChart) {
053 this.reportsToChart = reportsToChart;
054 }
055 public String getReportsToOrg() {
056 return reportsToOrg;
057 }
058 public void setReportsToOrg(String reportsToOrg) {
059 this.reportsToOrg = reportsToOrg;
060 }
061 public boolean hasParent() {
062 return !(getFinCoaCd().equals(getReportsToChart()) && getOrgCd().equals(getReportsToOrg()));
063 }
064 }