/** * A method that compares this WaveAudioEssenceDescriptorBO with the object that was passed in and returns true/false depending on whether the objects * match field for field. * Note: If the object passed in is not an instance of a WaveAudioEssenceDescriptorBO this method would return * false. * @param other the object that this parsed WaveAudioEssenceDescriptor should be compared with * @return result of comparing this parsed WaveAudioEssenceDescriptor with the object that was passed in */ public boolean equals(Object other) { if(!(other instanceof WaveAudioEssenceDescriptorBO)) { return false; } WaveAudioEssenceDescriptorBO otherObject = (WaveAudioEssenceDescriptorBO)other; if ((this.audio_sampling_rate == null) || (!this.audio_sampling_rate.equals(otherObject.audio_sampling_rate))) { return false; } if ((this.channelcount== null) || (!this.channelcount.equals(otherObject.channelcount))) { return false; } if ((this.quantization_bits == null) || (!this.quantization_bits.equals(otherObject.quantization_bits))) { return false; } return !((this.block_align == null) || (!this.block_align.equals(otherObject.block_align))); }
/** * Accessor for the SampleRate field * @return returns a list of long integers representing the numerator and denominator of the sample rate in that order */ public List<Long> getSampleRate(){ List<Long> list = new ArrayList<>(); Long numerator = this.sample_rate.getNumerator(); list.add(numerator); Long denominator = this.sample_rate.getDenominator(); list.add(denominator); return list; }
/** * Getter for the sum of hash codes of AudioSamplingRate, Channel Count, Quantization Bits and Block Align fields * of this WaveAudioEssenceDescriptor * @return the sum of hash codes of AudioSamplingRate, Channel Count, Quantization Bits and Block Align fields * of this WaveAudioEssenceDescriptor */ public int hashCode() { return this.audio_sampling_rate.hashCode() + this.channelcount.hashCode() + this.quantization_bits.hashCode() + this.block_align.hashCode(); }
CompoundDataTypes.Rational rational = new CompoundDataTypes.Rational(byteProvider); field.set(object, rational);
sb.append(this.indexEditRate.toString());
sb.append(super.sample_rate.toString()); sb.append(String.format("essence_container = %s%n", this.essence_container.toString())); sb.append(String.format("frame_layout = %d%n", this.frame_layout)); sb.append(String.format("stored_height = %d%n", this.stored_height)); sb.append("================== AspectRatio ======================\n"); sb.append(this.aspect_ratio.toString()); if (this.video_line_map != null)
this.instance_uid[12], this.instance_uid[13], this.instance_uid[14], this.instance_uid[15])); sb.append("================== SampleRate ======================\n"); sb.append(this.sample_rate.toString()); sb.append(String.format("essence_container = %s%n", this.essence_container.toString())); sb.append("================== AudioSamplingRate ======================\n"); sb.append(this.audio_sampling_rate.toString()); sb.append(String.format("channelcount = %d%n", this.channelcount)); sb.append(String.format("quantization_bits = %d%n", this.quantization_bits));
this.instance_uid[12], this.instance_uid[13], this.instance_uid[14], this.instance_uid[15])); sb.append("================== SampleRate ======================\n"); sb.append(this.sample_rate.toString()); sb.append(String.format("essence_container = %s%n", this.essence_container.toString())); sb.append(String.format("frame_layout = %d%n", this.frame_layout)); sb.append(String.format("stored_height = %d%n", this.stored_height)); sb.append("================== AspectRatio ======================\n"); sb.append(this.aspect_ratio.toString()); if (this.video_line_map != null)
/** * A method that returns a string representation of a Timeline Track object * * @return string representing the object */ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("================== TimelineTrack ======================\n"); sb.append(this.header.toString()); sb.append(String.format("instance_uid = 0x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%n", this.instance_uid[0], this.instance_uid[1], this.instance_uid[2], this.instance_uid[3], this.instance_uid[4], this.instance_uid[5], this.instance_uid[6], this.instance_uid[7], this.instance_uid[8], this.instance_uid[9], this.instance_uid[10], this.instance_uid[11], this.instance_uid[12], this.instance_uid[13], this.instance_uid[14], this.instance_uid[15])); sb.append(String.format("track_id = 0x%08x(%d)%n", this.track_id, this.track_id)); sb.append(String.format("track_number = 0x%08x(%d)%n", this.track_number, this.track_number)); sb.append(String.format("sequence = %s%n", this.sequence.toString())); sb.append("================== EditRate ======================\n"); sb.append(this.edit_rate.toString()); sb.append(String.format("origin = %d%n", this.origin)); return sb.toString(); } }
/** * A method that returns a string representation of a TimedTextDescriptorBO object * * @return string representing the object */ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("================== TimedTextDescriptor ======================\n"); sb.append(this.header.toString()); sb.append(String.format("instance_uid = 0x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%n", this.instance_uid[0], this.instance_uid[1], this.instance_uid[2], this.instance_uid[3], this.instance_uid[4], this.instance_uid[5], this.instance_uid[6], this.instance_uid[7], this.instance_uid[8], this.instance_uid[9], this.instance_uid[10], this.instance_uid[11], this.instance_uid[12], this.instance_uid[13], this.instance_uid[14], this.instance_uid[15])); if (this.subdescriptors != null) { sb.append(this.subdescriptors.toString()); } sb.append("================== SampleRate ======================\n"); sb.append(super.sample_rate.toString()); sb.append(String.format("essence_container = %s%n", this.essence_container.toString())); return sb.toString(); } }
/** * Getter for the audio sampling rate numerator of this WaveAudioEssenceDescriptor * * @return audio sampling rate numerator in the inclusive range [1, Integer.MAX_VALUE] * @throws MXFException when audio sampling rate numerator is out of range */ public int getAudioSamplingRateNumerator() throws MXFException { long value = this.waveAudioEssenceDescriptorBO.audio_sampling_rate.getNumerator(); if ((value <=0) || (value > Integer.MAX_VALUE)) { throw new MXFException(String.format("Observed audio sampling rate numerator = %d, which is not supported at this time", value)); } return (int)value; }
/** * Getter for the audio sampling rate denominator of this WaveAudioEssenceDescriptor * * @return audio sampling rate denominator in the inclusive range [1, Integer.MAX_VALUE] * @throws MXFException when audio sampling rate denominator is out of range */ public int getAudioSamplingRateDenominator() throws MXFException { long value = this.waveAudioEssenceDescriptorBO.audio_sampling_rate.getDenominator(); if ((value <=0) || (value > Integer.MAX_VALUE)) { throw new MXFException(String.format("Observed audio sampling rate denominator = %d, which is not supported at this time", value)); } return (int)value; }
/** * Getter for the numerator of this Timeline Track's edit rate * @return the numerator of this Timeline Track's edit rate */ public long getEditRateNumerator() { return this.timelineTrackBO.edit_rate.getNumerator(); }
/** * Getter for the denominator of this Timeline Track's edit rate * @return the denominator of this Timeline Track's edit rate */ public long getEditRateDenominator() { return this.timelineTrackBO.edit_rate.getDenominator(); }