Class: DCSerializer
- Inherits:
-
ASpaceExport::Serializer
show all
- Defined in:
- backend/app/exporters/serializers/dc.rb
Instance Method Summary
(collapse)
inherited, serializer_for, serializer_for?, with_namespace
Instance Method Details
- (Object) build(dc, opts = {})
4
5
6
7
8
9
10
11
|
# File 'backend/app/exporters/serializers/dc.rb', line 4
def build(dc, opts = {})
builder = Nokogiri::XML::Builder.new(:encoding => "UTF-8") do |xml|
_root(dc, xml)
end
builder
end
|
- (Object) serialize(dc, opts = {})
13
14
15
16
17
18
|
# File 'backend/app/exporters/serializers/dc.rb', line 13
def serialize(dc, opts = {})
builder = build(dc, opts)
builder.to_xml
end
|