001/** 002 * Copyright (C) 2007 - 2016, Jens Lehmann 003 * 004 * This file is part of DL-Learner. 005 * 006 * DL-Learner is free software; you can redistribute it and/or modify 007 * it under the terms of the GNU General Public License as published by 008 * the Free Software Foundation; either version 3 of the License, or 009 * (at your option) any later version. 010 * 011 * DL-Learner is distributed in the hope that it will be useful, 012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 014 * GNU General Public License for more details. 015 * 016 * You should have received a copy of the GNU General Public License 017 * along with this program. If not, see <http://www.gnu.org/licenses/>. 018 */ 019package org.dllearner.algorithms.decisiontrees.tdt.model; 020 021/** 022 * Abstract class for induced Tree model 023 * @author Utente 024 * 025 */ 026public abstract class AbstractTree extends AbstractModel{ 027 protected int pos, neg, und; 028 public int getPos() { 029 return pos; 030 } 031 032 public void setPos() { 033 this.pos++; 034 } 035 036 public int getNeg() { 037 return neg; 038 } 039 040 public void setNeg(int neg) { 041 this.neg++; 042 } 043 044 public int getUnd() { 045 return und; 046 } 047 048 public void setUnd() { 049 this.und++; 050 } 051 052 protected int match, omission, commission, induction; 053 protected boolean visited; 054 055 056 public int getMatch() { 057 return match; 058 } 059 060 public void setMatch(int match) { 061 this.match++; 062 } 063 064 public int getOmission() { 065 return omission; 066 } 067 068 public void setOmission(int omission) { 069 this.omission++; 070 } 071 072 public int getCommission() { 073 return commission; 074 } 075 076 public void setCommission(int commission) { 077 this.commission++; 078 } 079 080 public int getInduction() { 081 return induction; 082 } 083 084 public void setInduction(int induction) { 085 this.induction++; 086 } 087 public void setAsVisited(){ 088 089 visited=true; 090 091 } 092 093 public boolean isVisited(){ 094 095 return visited; 096 } 097 098 099 100}