PHP Object Copy Properties: Copy values of an object to another

Recommend this page to a friend!
  Info   View files Example   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2021-07-27 (1 month ago) RSS 2.0 feedNot yet rated by the usersTotal: 51 All time: 10,061 This week: 217Up
Version License PHP version Categories
php-object-copy 1.0GNU General Publi...5PHP 5, Data types
Description Author

The package can copy values of an object to another.

It can take as parameters two given objects and uses reflection to discover their class variables, so it can copy those class variable values from the source object to the destination object.

The class can use getter functions to get the source object class variable values and setter functions to set the destination object class variable values.

It may also optionally exclude from the copy process class variables that are private, or static or protected.

Picture of Juraj Puchký
  Performance   Level  
Name: Juraj Puchký <contact>
Classes: 16 packages by
Country: Czech Republic Czech Republic
Innovation award
Innovation award
Nominee: 6x

Details

php-object-copy

Simple implementation of copy properties from one object to another by Reflection API.

  Files folder image Files  
File Role Description
Files folder imageexamples (1 file)
Files folder imagesrc (1 file)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files  /  examples  
File Role Description
  Accessible without login Plain text file simple-copy.php Example Example script

  Files folder image Files  /  src  
File Role Description
  Plain text file ObjectCopier.php Class Class source

 Version Control Unique User Downloads Download Rankings  
 100%
Total:51
This week:0
All time:10,061
This week:217Up
For more information send a message to info at phpclasses dot org.