Ejemplo n.º 1
0
            public void parse(String line, ParseState state)
            {
                lineParser.parse(line, state);
                Match match = ParseUtil.match(Constants.EXT_X_BYTERANGE_PATTERN, line, getTag());

                state.getMedia().byteRange = ParseUtil.matchByteRange(match);
            }
Ejemplo n.º 2
0
                public void parse(Attribute attribute, MapInfo.Builder builder, ParseState state)
                {
                    Match match = Constants.EXT_X_BYTERANGE_VALUE_PATTERN.Match(ParseUtil.parseQuotedString(attribute.value));

                    if (!match.Success)
                    {
                        throw ParseException.create(ParseExceptionType.INVALID_BYTERANGE_FORMAT, tag: null, context: attribute.ToString());
                    }

                    builder.withByteRange(ParseUtil.matchByteRange(match));
                }