-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Lots of changes toward supporting inline tags (so the same tag can sh…
…ow multiple times, periodically through the file list).
- Loading branch information
Justin Greer
committed
Oct 16, 2011
1 parent
21fa41e
commit 5097159
Showing
7 changed files
with
123 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
class M3Uzi | ||
class Comment < Item | ||
|
||
attr_accessor :text | ||
|
||
def format | ||
"# #{text}" | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
class M3Uzi | ||
class Item | ||
|
||
def valid? | ||
true | ||
end | ||
|
||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,23 @@ | ||
class M3Uzi | ||
|
||
class Tag | ||
class Tag < Item | ||
|
||
attr_reader :name | ||
attr_accessor :value | ||
|
||
VALID_TAGS = %w{TARGETDURATION MEDIA-SEQUENCE ALLOW-CACHE} | ||
|
||
def name=(n) | ||
@name = n.to_s.upcase.gsub("_", "-") | ||
end | ||
|
||
def format | ||
string = '#' | ||
string << "EXT-X-" if VALID_TAGS.include?(name) | ||
string << name | ||
string << ":#{value}" if value | ||
string | ||
end | ||
|
||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
class M3Uzi | ||
VERSION = '0.2.0' | ||
VERSION = '0.3.0' | ||
end |