Skip to content

Remove FileAddress from layaout interfaces #24

@magicDGS

Description

@magicDGS

To make the interface independent of our FileAddress object, we should return a number value instead of the object itself to allow other implementations to get rid of our abstraction. There are two possibilities:

  • Return a long. This will allow to seek directly a file by using the returned value, and it will enforce a maximum value for the implementations. We are not planning to support pointers larger than a long yet (I have to think how that can be done).
  • Return a Number. Like that, some implementations can use BigIntegeror their own number implementation: e.g., our FileAddress can extend Number to be used directly. In this case, we should point in our javadoc that the number will be converted to long for being seek, so arithmetic exceptions should be considered.

I prefer the first point, because like that all the enforcing is implementation-dependent. Something similar will be done with the object sizes.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions