PageRenderTime 173ms CodeModel.GetById 80ms app.highlight 7ms RepoModel.GetById 84ms app.codeStats 0ms

/src/mpv5/db/objects/WebShop.java

http://mp-rechnungs-und-kundenverwaltung.googlecode.com/
Java | 157 lines | 72 code | 24 blank | 61 comment | 0 complexity | 43af15530f4623fe41b94c39b4568199 MD5 | raw file
  1/*
  2 *  This file is part of YaBS.
  3 *
  4 *      YaBS is free software: you can redistribute it and/or modify
  5 *      it under the terms of the GNU General Public License as published by
  6 *      the Free Software Foundation, either version 3 of the License, or
  7 *      (at your option) any later version.
  8 *
  9 *      YaBS is distributed in the hope that it will be useful,
 10 *      but WITHOUT ANY WARRANTY; without even the implied warranty of
 11 *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 12 *      GNU General Public License for more details.
 13 *
 14 *      You should have received a copy of the GNU General Public License
 15 *      along with YaBS.  If not, see <http://www.gnu.org/licenses/>.
 16 */
 17package mpv5.db.objects;
 18
 19import javax.swing.JComponent;
 20import mpv5.db.common.Context;
 21import mpv5.db.common.DatabaseObject;
 22import mpv5.utils.images.MPIcon;
 23import mpv5.utils.text.RandomText;
 24
 25/**
 26 * Represents a WebShop
 27 */
 28public class WebShop extends DatabaseObject {
 29
 30    private String description = "";
 31    private int interv;
 32    private String url = "";
 33    private boolean isrequestCompression;
 34    private boolean isauthenticated;
 35    private String username = "";
 36    private String passw = "";
 37
 38    public WebShop() {
 39        setContext(Context.getWebShop());
 40    }
 41
 42    @Override
 43    public JComponent getView() {
 44        return null;
 45    }
 46
 47    @Override
 48    public MPIcon getIcon() {
 49        return null;
 50    }
 51
 52    /**
 53     * @return the description
 54     */
 55    public String __getDescription() {
 56        return description;
 57    }
 58
 59    /**
 60     * @param description the description to set
 61     */
 62    public void setDescription(String description) {
 63        this.description = description;
 64    }
 65
 66    /**
 67     * @return the interval
 68     */
 69    public int __getInterv() {
 70        return interv;
 71    }
 72
 73    /**
 74     * @param interval the interval to set
 75     */
 76    public void setInterv(int interval) {
 77        this.interv = interval;
 78    }
 79
 80    /**
 81     * @return the url
 82     */
 83    public String __getUrl() {
 84        return url;
 85    }
 86
 87    /**
 88     * @param url the url to set
 89     */
 90    public void setUrl(String url) {
 91        this.url = url;
 92    }
 93
 94        @Override
 95    public void ensureUniqueness() {
 96         setCname("-" + RandomText.getNumberText()  + "- (" + __getUrl() +")");
 97    }
 98
 99    /**
100     * @return the isrequestCompression
101     */
102    public boolean __getIsrequestCompression() {
103        return isrequestCompression;
104    }
105
106    /**
107     * @param isrequestCompression the isrequestCompression to set
108     */
109    public void setIsrequestCompression(boolean isrequestCompression) {
110        this.isrequestCompression = isrequestCompression;
111    }
112
113    /**
114     * @return the isauthenticated
115     */
116    public boolean __getIsauthenticated() {
117        return isauthenticated;
118    }
119
120    /**
121     * @param isauthenticated the isauthenticated to set
122     */
123    public void setIsauthenticated(boolean isauthenticated) {
124        this.isauthenticated = isauthenticated;
125    }
126
127    /**
128     * @return the username
129     */
130    public String __getUsername() {
131        return username;
132    }
133
134    /**
135     * @param username the username to set
136     */
137    public void setUsername(String username) {
138        this.username = username;
139    }
140
141    /**
142     * @return the password
143     */
144    public String __getPassw() {
145        return passw;
146    }
147
148    /**
149     * @param password the password to set
150     */
151    public void setPassw(String password) {
152        this.passw = password;
153    }
154
155
156
157}