diff options
author | James Ahlborn <jtahlborn@yahoo.com> | 2007-06-05 01:41:35 +0000 |
---|---|---|
committer | James Ahlborn <jtahlborn@yahoo.com> | 2007-06-05 01:41:35 +0000 |
commit | 5de2b053b8768c9a34aa2447a2b1d62ba0102f08 (patch) | |
tree | 5b569c007da9baabe4510dff2bce9ba94f5930a7 /src/java/com/healthmarketscience/jackcess/Column.java | |
parent | 98e48307a5a619ee124ad3a8ec423790e7d5eedf (diff) | |
download | jackcess-5de2b053b8768c9a34aa2447a2b1d62ba0102f08.tar.gz jackcess-5de2b053b8768c9a34aa2447a2b1d62ba0102f08.zip |
include format in validation
git-svn-id: https://svn.code.sf.net/p/jackcess/code/jackcess/trunk@147 f203690c-595d-4dc9-a70b-905162fa7fd2
Diffstat (limited to 'src/java/com/healthmarketscience/jackcess/Column.java')
-rw-r--r-- | src/java/com/healthmarketscience/jackcess/Column.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/java/com/healthmarketscience/jackcess/Column.java b/src/java/com/healthmarketscience/jackcess/Column.java index c455575..033e933 100644 --- a/src/java/com/healthmarketscience/jackcess/Column.java +++ b/src/java/com/healthmarketscience/jackcess/Column.java @@ -269,7 +269,11 @@ public class Column implements Comparable<Column> { * * @throw IllegalArgumentException if this column definition is invalid. */ - public void validate() { + public void validate(JetFormat format) { + if(_format != format) { + throw new IllegalArgumentException("format must be " + format + + " but is " + _format); + } if(getType() == null) { throw new IllegalArgumentException("must have type"); } |