org.red5.io.flv.meta

## Class MetaService

- java.lang.Object
- - org.red5.io.flv.meta.MetaService

All Implemented Interfaces:
  IMetaService

    public class MetaService
    extends Object
    implements IMetaService

MetaService represents a MetaData service in Spring

Author:
  The Red5 Project (red5@osflash.org), Dominick Accattato (daccattato@gmail.com), Luke Hubbard, Codegent Ltd (luke@codegent.com)

### Field Summary

Fields
`protected static org.slf4j.Logger` `log`

### Constructor Summary

Constructors
Constructor and Description
`MetaService()` MetaService constructor
`MetaService(File poFil)`

### Method Summary

Methods
`Deserializer` `getDeserializer()`
`File` `getFile()` Returns the file being accessed
`Serializer` `getSerializer()`
`static IMeta` `mergeMeta(IMetaData<?,?> metaData1, IMetaData<?,?> metaData2)` Merges the two Meta objects
`IMetaCue[]` `readMetaCue()` Read the Meta Cue Points
`MetaData<?,?>` `readMetaData(IoBuffer buffer)` Read the MetaData
`void` `setDeserializer(Deserializer deserializer)`
`void` `setFile(File file)` Media file to be accessed
`void` `setSerializer(Serializer serializer)`
`void` `write(IMetaData<?,?> meta)` Initiates writing of the MetaData
`void` `writeMetaCue()` Writes the Meta Cue Points
`void` `writeMetaData(IMetaData<?,?> metaData)` Writes the MetaData

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### log

    protected static org.slf4j.Logger log

### Constructor Detail

#### MetaService

    public MetaService()

MetaService constructor

#### MetaService

    public MetaService(File poFil)

### Method Detail

#### getDeserializer

    public Deserializer getDeserializer()

Returns:
  Returns the deserializer.

#### setDeserializer

    public void setDeserializer(Deserializer deserializer)

Parameters:
  `deserializer` - The deserializer to set.

#### getSerializer

    public Serializer getSerializer()

Returns:
  Returns the serializer.

#### setSerializer

    public void setSerializer(Serializer serializer)

Parameters:
  `serializer` - The serializer to set.

#### write

    public void write(IMetaData<?,?> meta)
               throws IOException

Initiates writing of the MetaData

Specified by:
  `write` in interface `IMetaService`
Parameters:
  `meta` - Metadata
Throws:
  `IOException` - I/O exception

#### mergeMeta

    public static IMeta mergeMeta(IMetaData<?,?> metaData1,
                  IMetaData<?,?> metaData2)

Merges the two Meta objects

Parameters:
  `metaData1` - First metadata object
  `metaData2` - Second metadata object
Returns:
  Merged metadata

#### writeMetaData

    public void writeMetaData(IMetaData<?,?> metaData)

Writes the MetaData

Specified by:
  `writeMetaData` in interface `IMetaService`
Parameters:
  `metaData` - Metadata

#### writeMetaCue

    public void writeMetaCue()

Writes the Meta Cue Points

Specified by:
  `writeMetaCue` in interface `IMetaService`

#### getFile

    public File getFile()

Description copied from interface: `IMetaService`
Returns the file being accessed

Specified by:
  `getFile` in interface `IMetaService`
Returns:
  Returns the file.

#### setFile

    public void setFile(File file)

Description copied from interface: `IMetaService`
Media file to be accessed

Specified by:
  `setFile` in interface `IMetaService`
Parameters:
  `file` - The file to set.

#### readMetaData

    public MetaData<?,?> readMetaData(IoBuffer buffer)

Read the MetaData

Specified by:
  `readMetaData` in interface `IMetaService`
Parameters:
  `buffer` - IoBuffer source
Returns:
  metaData Metadata

#### readMetaCue

    public IMetaCue[] readMetaCue()

Read the Meta Cue Points

Specified by:
  `readMetaCue` in interface `IMetaService`
Returns:
  Meta cue points