From 2e5d00ef438b61aefec56420499ae7e1eb75aacb Mon Sep 17 00:00:00 2001 From: James Ahlborn Date: Tue, 15 Oct 2013 01:16:46 +0000 Subject: [PATCH] make RowIdImpl serializable; clean up some formatting git-svn-id: https://svn.code.sf.net/p/jackcess/code/jackcess/trunk@831 f203690c-595d-4dc9-a70b-905162fa7fd2 --- .../com/healthmarketscience/jackcess/impl/RowIdImpl.java | 8 ++++++-- .../com/healthmarketscience/jackcess/impl/RowImpl.java | 9 +++------ 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/main/java/com/healthmarketscience/jackcess/impl/RowIdImpl.java b/src/main/java/com/healthmarketscience/jackcess/impl/RowIdImpl.java index 7524f1c..3648c91 100644 --- a/src/main/java/com/healthmarketscience/jackcess/impl/RowIdImpl.java +++ b/src/main/java/com/healthmarketscience/jackcess/impl/RowIdImpl.java @@ -27,8 +27,10 @@ King of Prussia, PA 19406 package com.healthmarketscience.jackcess.impl; -import org.apache.commons.lang.builder.CompareToBuilder; +import java.io.Serializable; + import com.healthmarketscience.jackcess.RowId; +import org.apache.commons.lang.builder.CompareToBuilder; /** @@ -36,8 +38,10 @@ import com.healthmarketscience.jackcess.RowId; * * @author James Ahlborn */ -public class RowIdImpl implements RowId +public class RowIdImpl implements RowId, Serializable { + private static final long serialVersionUID = 20131014L; + /** special page number which will sort before any other valid page number */ public static final int FIRST_PAGE_NUMBER = -1; diff --git a/src/main/java/com/healthmarketscience/jackcess/impl/RowImpl.java b/src/main/java/com/healthmarketscience/jackcess/impl/RowImpl.java index 31f2c43..2191bf2 100644 --- a/src/main/java/com/healthmarketscience/jackcess/impl/RowImpl.java +++ b/src/main/java/com/healthmarketscience/jackcess/impl/RowImpl.java @@ -37,19 +37,16 @@ public class RowImpl extends LinkedHashMap implements Row private final RowIdImpl _id; - public RowImpl(RowIdImpl id) - { + public RowImpl(RowIdImpl id) { _id = id; } - public RowImpl(RowIdImpl id, int expectedSize) - { + public RowImpl(RowIdImpl id, int expectedSize) { super(expectedSize); _id = id; } - public RowImpl(Row row) - { + public RowImpl(Row row) { super(row); _id = (RowIdImpl)row.getId(); } -- 2.39.5