Sha256: d26d97fd86bcf440a299a1667cc0d9b2d2c6adfc05dd62403476e72c7a63d986
Contents?: true
Size: 1.12 KB
Versions: 3
Compression:
Stored size: 1.12 KB
Contents
[![Gem Version](https://badge.fury.io/rb/activefedora-aggregation.svg)](http://badge.fury.io/rb/activefedora-aggregation) [![Build Status](https://circleci.com/gh/projecthydra-labs/activefedora-aggregation.svg?style=shield&circle-token=:circle-token)](https://circleci.com/gh/projecthydra-labs/activefedora-aggregation) # ActiveFedora::Aggregation Aggregations for ActiveFedora: manage a group of related objects using predicates from the [OAI-ORE data model](http://www.openarchives.org/ore/1.0/datamodel). Provides the foundation for flexible relationships, including items appearing multiple times in a group, flexible/optional ordering, etc. Used extensively by [Hydra::PCDM](https://github.com/projecthydra-labs/hydra-pcdm/). ### Example ```ruby class GenericFile < ActiveFedora::Base end generic_file1 = GenericFile.create(id: 'file1') generic_file2 = GenericFile.create(id: 'file2') class Image < ActiveFedora::Base aggregates :generic_files end image = Image.create(id: 'my_image') image.generic_files = [generic_file2, generic_file1] image.save ``` Now the `generic_files` method returns an ordered list of GenericFile objects.
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
activefedora-aggregation-0.4.2 | README.md |
activefedora-aggregation-0.4.1 | README.md |
activefedora-aggregation-0.4.0 | README.md |