Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| PDF Clown 0.1.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.pdfclown.documents.contents.composition
Class Length

    java.lang.Object
      org.pdfclown.documents.contents.composition.Length

    public final class Length

extends Object

Distance measure.

Since:
  0.0.8.3
Version:
  0.1.2, 01/20/12
Author:
  Stefano Chizzolini (http://www.stefanochizzolini.it)

Nested Class Summary
`static class` | `Length.UnitModeEnum` Measurement mode.

Constructor Summary
`Length(double value, Length.UnitModeEnum unitMode)`

Method Summary
`Length.UnitModeEnum` | `getUnitMode()` Gets the measurement mode applied to the `distance value`.
`double` | `getValue()` Gets the distance value.
`double` | `getValue(double baseValue)` Gets the resolved distance value.
`void` | `setUnitMode(Length.UnitModeEnum value)`
`void` | `setValue(double value)`
`String` | `toString()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### Length

    public Length(double value,
                  Length.UnitModeEnum unitMode)

Method Detail

### getUnitMode

    public Length.UnitModeEnum getUnitMode()

  Gets the measurement mode applied to the `distance value`.

### getValue

    public double getValue()

  Gets the distance value.

  According to the applied `unit mode`, this value can be either an absolute measure or a ratio to be resolved through a base value.

  See Also:
    `getValue(double)`

### getValue

    public double getValue(double baseValue)

  Gets the resolved distance value.

  This method ensures that relative distance values are transformed according to the specified base value.

  Parameters:
    `baseValue` - Value used to resolve relative values.

### setUnitMode

    public void setUnitMode(Length.UnitModeEnum value)

### setValue

    public void setValue(double value)

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| PDF Clown 0.1.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Project home page
Copyright © 2006-2013 Stefano Chizzolini. Some Rights Reserved.
This documentation is available under the terms of the GNU Free Documentation License.