Class: TagLib::MPEG::File
Overview
An MPEG file class with some useful methods specific to MPEG. .
This implements the generic TagLib::File API and additionally provides access to properties that are distinct to MPEG files, notably access to the different ID3 tags.
Instance Method Summary collapse
-
#APETag(create = false) ⇒ Object
Returns a pointer to the APE tag of the file.If create is false (the default) this will return a null pointer if there is no valid APE tag.
-
#audioProperties ⇒ Object
Returns the MPEG::Properties for this file.
- #clear ⇒ Object
- #find1 ⇒ Object
- #find2 ⇒ Object
- #find3 ⇒ Object
-
#firstFrameOffset ⇒ Object
Returns the position in the file of the first MPEG frame.
-
#ID3v1Tag(create = false) ⇒ Object
Returns a pointer to the ID3v1 tag of the file.If create is false (the default) this will return a null pointer if there is no valid ID3v1 tag.
-
#ID3v2Tag(create = false) ⇒ Object
Returns a pointer to the ID3v2 tag of the file.If create is false (the default) this will return a null pointer if there is no valid ID3v2 tag.
- #insert ⇒ Object
- #isOpen ⇒ Object
- #isValid ⇒ Object
- #isWritable ⇒ Object
-
#lastFrameOffset ⇒ Object
Returns the position in the file of the last MPEG frame.
- #length ⇒ Object
- #name ⇒ Object
-
#nextFrameOffset(position) ⇒ Object
Returns the position in the file of the next MPEG frame, using the current position as start.
- #open? ⇒ Boolean
-
#previousFrameOffset(position) ⇒ Object
Returns the position in the file of the previous MPEG frame, using the current position as start.
- #read_only? ⇒ Boolean
- #readBlock ⇒ Object
- #readOnly ⇒ Object
- #removeBlock ⇒ Object
- #rfind ⇒ Object
-
#save(tags, stripOthers) ⇒ Object
Save the file.
- #seek ⇒ Object
-
#setID3v2FrameFactory(factory) ⇒ Object
Set the ID3v2::FrameFactory to something other than the default.ID3v2FrameFactory.
-
#strip(tags, freeMemory) ⇒ Object
This will strip the tags that match the OR-ed together TagTypes from the file.
-
#tag ⇒ Object
Returns a pointer to a tag that is the union of the ID3v2 and ID3v1 tags.
- #tell ⇒ Object
- #valid? ⇒ Boolean
- #writable? ⇒ Boolean
- #writeBlock ⇒ Object
Instance Method Details
#APETag(create = false) ⇒ Object
Returns a pointer to the APE tag of the file.If create is false (the default) this will return a null pointer if there is no valid APE tag. If create is true it will create an APE tag if one does not exist.The Tag is still owned by the MPEG::File and should not be deleted by the user. It will be deleted when the file (object) is destroyed.
1662 1663 |
# File 'lib/TagLib_doc.rb', line 1662 def APETag(create = false) end |
#audioProperties ⇒ Object
Returns the MPEG::Properties for this file. If no audio properties were read then this will return a null pointer.
1671 1672 |
# File 'lib/TagLib_doc.rb', line 1671 def audioProperties() end |
#clear ⇒ Object
1616 1617 |
# File 'lib/TagLib_doc.rb', line 1616 def clear() end |
#find1 ⇒ Object
1656 1657 |
# File 'lib/TagLib_doc.rb', line 1656 def find1() end |
#find2 ⇒ Object
1680 1681 |
# File 'lib/TagLib_doc.rb', line 1680 def find2() end |
#find3 ⇒ Object
1600 1601 |
# File 'lib/TagLib_doc.rb', line 1600 def find3() end |
#firstFrameOffset ⇒ Object
Returns the position in the file of the first MPEG frame.
1621 1622 |
# File 'lib/TagLib_doc.rb', line 1621 def firstFrameOffset() end |
#ID3v1Tag(create = false) ⇒ Object
Returns a pointer to the ID3v1 tag of the file.If create is false (the default) this will return a null pointer if there is no valid ID3v1 tag. If create is true it will create an ID3v1 tag if one does not exist.The Tag is still owned by the MPEG::File and should not be deleted by the user. It will be deleted when the file (object) is destroyed.
1610 1611 |
# File 'lib/TagLib_doc.rb', line 1610 def ID3v1Tag(create = false) end |
#ID3v2Tag(create = false) ⇒ Object
Returns a pointer to the ID3v2 tag of the file.If create is false (the default) this will return a null pointer if there is no valid ID3v2 tag. If create is true it will create an ID3v2 tag if one does not exist.The Tag is still owned by the MPEG::File and should not be deleted by the user. It will be deleted when the file (object) is destroyed.
1688 1689 |
# File 'lib/TagLib_doc.rb', line 1688 def ID3v2Tag(create = false) end |
#insert ⇒ Object
1664 1665 |
# File 'lib/TagLib_doc.rb', line 1664 def insert() end |
#isOpen ⇒ Object
1604 1605 |
# File 'lib/TagLib_doc.rb', line 1604 def isOpen() end |
#isValid ⇒ Object
1654 1655 |
# File 'lib/TagLib_doc.rb', line 1654 def isValid() end |
#isWritable ⇒ Object
1594 1595 |
# File 'lib/TagLib_doc.rb', line 1594 def isWritable() end |
#lastFrameOffset ⇒ Object
Returns the position in the file of the last MPEG frame.
1700 1701 |
# File 'lib/TagLib_doc.rb', line 1700 def lastFrameOffset() end |
#length ⇒ Object
1682 1683 |
# File 'lib/TagLib_doc.rb', line 1682 def length() end |
#name ⇒ Object
1596 1597 |
# File 'lib/TagLib_doc.rb', line 1596 def name() end |
#nextFrameOffset(position) ⇒ Object
Returns the position in the file of the next MPEG frame, using the current position as start
1647 1648 |
# File 'lib/TagLib_doc.rb', line 1647 def nextFrameOffset(position) end |
#open? ⇒ Boolean
1642 1643 |
# File 'lib/TagLib_doc.rb', line 1642 def open?() end |
#previousFrameOffset(position) ⇒ Object
Returns the position in the file of the previous MPEG frame, using the current position as start
1676 1677 |
# File 'lib/TagLib_doc.rb', line 1676 def previousFrameOffset(position) end |
#read_only? ⇒ Boolean
1602 1603 |
# File 'lib/TagLib_doc.rb', line 1602 def read_only?() end |
#readBlock ⇒ Object
1612 1613 |
# File 'lib/TagLib_doc.rb', line 1612 def readBlock() end |
#readOnly ⇒ Object
1666 1667 |
# File 'lib/TagLib_doc.rb', line 1666 def readOnly() end |
#removeBlock ⇒ Object
1638 1639 |
# File 'lib/TagLib_doc.rb', line 1638 def removeBlock() end |
#rfind ⇒ Object
1614 1615 |
# File 'lib/TagLib_doc.rb', line 1614 def rfind() end |
#save(tags, stripOthers) ⇒ Object
Save the file. This will attempt to save all of the tag types that are specified by OR-ing together TagTypes values. The save() method above uses AllTags. This returns true if saving was successful.If stripOthers is true this strips all tags not included in the mask, but does not modify them in memory, so later calls to save() which make use of these tags will remain valid. This also strips empty tags.
1695 1696 |
# File 'lib/TagLib_doc.rb', line 1695 def save(,stripOthers) end |
#seek ⇒ Object
1598 1599 |
# File 'lib/TagLib_doc.rb', line 1598 def seek() end |
#setID3v2FrameFactory(factory) ⇒ Object
Set the ID3v2::FrameFactory to something other than the default.ID3v2FrameFactory
1636 1637 |
# File 'lib/TagLib_doc.rb', line 1636 def setID3v2FrameFactory(factory) end |
#strip(tags, freeMemory) ⇒ Object
This will strip the tags that match the OR-ed together TagTypes from the file. By default it strips all tags. It returns true if the tags are successfully stripped.If freeMemory is true the ID3 and APE tags will be deleted and pointers to them will be invalidated.
1652 1653 |
# File 'lib/TagLib_doc.rb', line 1652 def strip(,freeMemory) end |
#tag ⇒ Object
Returns a pointer to a tag that is the union of the ID3v2 and ID3v1 tags. The ID3v2 tag is given priority in reading the information – if requested information exists in both the ID3v2 tag and the ID3v1 tag, the information from the ID3v2 tag will be returned.If you would like more granular control over the content of the tags, with the concession of generality, use the tag-type specific calls.As this tag is not implemented as an ID3v2 tag or an ID3v1 tag, but a union of the two this pointer may not be cast to the specific tag types. ID3v1Tag() ID3v2Tag() APETag()
1628 1629 |
# File 'lib/TagLib_doc.rb', line 1628 def tag() end |
#tell ⇒ Object
1678 1679 |
# File 'lib/TagLib_doc.rb', line 1678 def tell() end |
#valid? ⇒ Boolean
1690 1691 |
# File 'lib/TagLib_doc.rb', line 1690 def valid?() end |
#writable? ⇒ Boolean
1640 1641 |
# File 'lib/TagLib_doc.rb', line 1640 def writable?() end |
#writeBlock ⇒ Object
1630 1631 |
# File 'lib/TagLib_doc.rb', line 1630 def writeBlock() end |