Skip to content

Releases: luads/php-xbase

2.2.0

15 Aug 13:49
b7fb1da
Compare
Choose a tag to compare

What's Changed

  • Create encoder: MbConvertEncodingEncoder by @honginho in #120
  • add AllowDynamicProperties for XBase\Header\Column::* properties to fix deprecation warnings by @Haehnchen in #127

New Contributors

Full Changelog: 2.1.3...2.2.0

2.1.0

20 Oct 11:00
9247c04
Compare
Choose a tag to compare

Features

#109 replaceable encoder for converters (@retnek)

2.0.0 TableCreator

21 Mar 17:30
Compare
Choose a tag to compare

New features

  • TableCreator allows you to create DBF table files.

Breaking changes

  • Table replaced by TableReader
  • WritableTable replaced by TableEditor
  • removed all Record methods like get*() except get and getDateTimeObject.
  • removed all Record methods like set*() except set

1.4.0

21 Mar 11:13
Compare
Choose a tag to compare

Deprecations

  • Use XBase\TableReader instead of XBase\Table
  • Use XBase\TableEditor instead of XBase\WritableTable.

1.3.4

17 Feb 18:01
8029865
Compare
Choose a tag to compare

#101 Add test file for DBase 7 Double type (@aaronhuisinga)

1.3.2 WritableTable `editMode` option

09 Dec 14:13
Compare
Choose a tag to compare
  • Table::__constructor accepts second argument as an options array. Available options: encoding, columns.
use XBase\Table;

// before 1.3.2
$table = new Table(
    __DIR__.'/Resources/foxpro/1.dbf', 
    ['column1', 'column2'], 
    'cp852'
);

// since 1.3.2
$table = new Table(
    __DIR__.'/Resources/foxpro/1.dbf', 
    [
        'columns' => ['column1', 'column2'], 
        'encoding' => 'cp852'
    ]
);
  • WritableTable editMode option.
    • clone Default. Creates a clone of original file and applies all changes to it. To save changes you need to call save method.
    • realtime Immediately apply changes for original table file. Changes cannot be undone.
use XBase\WritableTable;

// clone edit mode
$tableWrite = new WritableTable(
    'file.dbf', 
    [
        'encoding' => 'cp866',
        'editMode' => WritableTable::EDIT_MODE_CLONE,
    ]
);
// do edits
$tableWrite
    ->save()
    ->close();

// realtime edit mode
$tableWrite = new WritableTable(
    'file.dbf', 
    [
        'encoding' => 'cp866',
        'editMode' => WritableTable::EDIT_MODE_REALTIME,
    ]
);
// do edits
$tableWrite->close();

1.3.1

05 Nov 14:06
Compare
Choose a tag to compare

Fixes

#94 VisualFoxPro\DateTimeConverter (@ebta)

1.3.0

30 Sep 19:02
Compare
Choose a tag to compare

Features

add

  • declare(strict_types=1); for all files
  • Ability to add, edit and delete memo entries for VFP, Foxpro and DBase7.
  • All setters return $this.
  • RecordInterface::get('name') is main getter
  • RecordInterface::set('name', $value) is main setter
  • WritableTable::save you should use it to save table changes.

changes

  • Getter for type D (Date) returns date string in 'Ymd' format instead of timestamp.
  • VisualFoxproRecord::getDateTime returns object of \DateTimeInterface instead of timestamp.

deprecations

  • RecordInterface::getObject
  • RecordInterface::setObject
  • Setters like Record::setType. Use set('name', $value) method instead.
  • Getters like Record::getType. Use get('name') method instead.
  • WritableTable::openWrite. Method is no longer needed.

fixes

  • Can't add/update memo field (long text) #91
  • Missing end-of-file marker #43

1.2.2

10 Sep 15:59
Compare
Choose a tag to compare

fixed #89

1.2.1

03 Aug 10:05
Compare
Choose a tag to compare
fixed #88