1 /* Copyright (C) 2004-2007  The Chemistry Development Kit (CDK) project
2  *
3  * Contact: cdk-devel@lists.sourceforge.net
4  *
5  * This program is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public License
7  * as published by the Free Software Foundation; either version 2.1
8  * of the License, or (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18  */
19 package org.openscience.cdk.isomorphism.matchers.smarts;
20 
21 import org.openscience.cdk.interfaces.IAtom;
22 import org.openscience.cdk.CDKConstants;
23 import org.openscience.cdk.interfaces.IChemObjectBuilder;
24 
25 /**
26  * This matcher any non-aromatic atom. This assumes that aromaticity in the
27  * molecule has been perceived.
28  *
29  * @cdk.module  smarts
30  * @cdk.githash
31  * @cdk.keyword SMARTS
32  */
33 @Deprecated
34 public class AliphaticAtom extends SMARTSAtom {
35 
36     private static final long serialVersionUID = 5145049891214205622L;
37 
38     /**
39      * Creates a new instance
40      *
41      */
AliphaticAtom(IChemObjectBuilder builder)42     public AliphaticAtom(IChemObjectBuilder builder) {
43         super(builder);
44         setFlag(CDKConstants.ISALIPHATIC, true);
45     }
46 
47     /*
48      * (non-Javadoc)
49      * @see
50      * org.openscience.cdk.isomorphism.matchers.smarts.SMARTSAtom#matches(org
51      * .openscience.cdk.interfaces.IAtom)
52      */
53     @Override
matches(IAtom atom)54     public boolean matches(IAtom atom) {
55         return !atom.isAromatic();
56 
57     }
58 
59     /*
60      * (non-Javadoc)
61      * @see org.openscience.cdk.PseudoAtom#toString()
62      */
63     @Override
toString()64     public String toString() {
65         return "AliphaticAtom()";
66     }
67 }
68