public String getValue(FieldKey genericKey, int index) throws KeyNotFoundException { VorbisCommentFieldKey vorbisCommentFieldKey = tagFieldToOggField.get(genericKey); if (vorbisCommentFieldKey == null) { throw new KeyNotFoundException(); } return super.getItem(vorbisCommentFieldKey.getFieldName(), index); }
/** * Maps the generic key to the ogg key and return the list of values for this field * * @param genericKey */ @Override public List<TagField> getFields(FieldKey genericKey) throws KeyNotFoundException { VorbisCommentFieldKey vorbisCommentFieldKey = tagFieldToOggField.get(genericKey); if (vorbisCommentFieldKey == null) { throw new KeyNotFoundException(); } return super.getFields(vorbisCommentFieldKey.getFieldName()); }
/** * Create Tag Field using ogg key * * @param vorbisCommentFieldKey * @param value * @return * @throws org.jaudiotagger.tag.KeyNotFoundException * @throws org.jaudiotagger.tag.FieldDataInvalidException */ public TagField createField(VorbisCommentFieldKey vorbisCommentFieldKey, String value) throws KeyNotFoundException, FieldDataInvalidException { if (value == null) { throw new IllegalArgumentException(ErrorMessage.GENERAL_INVALID_NULL_ARGUMENT.getMsg()); } if (vorbisCommentFieldKey == null) { throw new KeyNotFoundException(); } return new VorbisCommentTagField(vorbisCommentFieldKey.getFieldName(), value); }
/** * Delete fields with this vorbisCommentFieldKey * * @param vorbisCommentFieldKey * @throws org.jaudiotagger.tag.KeyNotFoundException */ public void deleteField(VorbisCommentFieldKey vorbisCommentFieldKey) throws KeyNotFoundException { if (vorbisCommentFieldKey == null) { throw new KeyNotFoundException(); } super.deleteField(vorbisCommentFieldKey.getFieldName()); }
/** * Retrieve the first value that exists for this vorbis comment key * * @param vorbisCommentKey * @return * @throws org.jaudiotagger.tag.KeyNotFoundException */ public String getFirst(VorbisCommentFieldKey vorbisCommentKey) throws KeyNotFoundException { if (vorbisCommentKey == null) { throw new KeyNotFoundException(); } return super.getFirst(vorbisCommentKey.getFieldName()); }
/** * Retrieve the first value that exists for this vorbis comment key * * @param vorbisCommentKey * @return * @throws org.jaudiotagger.tag.KeyNotFoundException */ public List<TagField> get(VorbisCommentFieldKey vorbisCommentKey) throws KeyNotFoundException { if (vorbisCommentKey == null) { throw new KeyNotFoundException(); } return super.getFields(vorbisCommentKey.getFieldName()); }