Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

add extensions for 3rd parties to add meta info in an extendable way

  • Loading branch information...
commit 133e5249fb5f4c98de821f6bda030c7e7f7319a6 1 parent 39986fb
Dean Hiller authored
View
12 src/main/java/com/alvazan/orm/api/z8spi/meta/DboColumnMeta.java
@@ -3,9 +3,11 @@
import java.lang.reflect.Field;
import java.math.BigDecimal;
import java.math.BigInteger;
+import java.util.HashMap;
import java.util.List;
import java.util.Map;
+import com.alvazan.orm.api.base.anno.NoSqlEmbedded;
import com.alvazan.orm.api.base.anno.NoSqlEntity;
import com.alvazan.orm.api.base.anno.NoSqlId;
import com.alvazan.orm.api.base.anno.NoSqlIndexed;
@@ -46,6 +48,13 @@
protected transient BaseConverter converter;
+ /**
+ * Specifically not for playorm but for clients of playorm that want to add meta data
+ * to the DboTableMeta object
+ */
+ @NoSqlEmbedded
+ private Map<String, String> extensions = new HashMap<String, String>();
+
public String getId() {
return id;
}
@@ -366,4 +375,7 @@ public boolean isJodaType() {
return false;
}
+ public Map<String, String> getExtensions() {
+ return extensions;
+ }
}
View
13 src/main/java/com/alvazan/orm/api/z8spi/meta/DboTableMeta.java
@@ -15,6 +15,7 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+import com.alvazan.orm.api.base.anno.NoSqlEmbedded;
import com.alvazan.orm.api.base.anno.NoSqlEntity;
import com.alvazan.orm.api.base.anno.NoSqlId;
import com.alvazan.orm.api.base.anno.NoSqlIndexed;
@@ -68,6 +69,13 @@
private String foreignKeyToExtensions;
+ /**
+ * Specifically not for playorm but for clients of playorm that want to add meta data
+ * to the DboTableMeta object
+ */
+ @NoSqlEmbedded
+ private Map<String, String> extensions = new HashMap<String, String>();
+
private transient List<DboColumnMeta> indexedColumnsCache;
private transient List<DboColumnMeta> cacheOfPartitionedBy;
@@ -502,5 +510,8 @@ public Long getTimeSeriesPartionSize() {
public void setTimeSeriesPartionSize(Long timeSeriesPartionSize) {
this.timeSeriesPartionSize = timeSeriesPartionSize;
}
-
+
+ public Map<String, String> getExtensions() {
+ return extensions;
+ }
}
Please sign in to comment.
Something went wrong with that request. Please try again.