Logo Search packages:      
Sourcecode: f-spot version File versions  Download package

static PrivateFrame TagLib::Id3v2::PrivateFrame::Get ( Tag  tag,
string  owner,
bool  create 
) [inline, static]

Gets a specified private frame from the specified tag, optionally creating it if it does not exist.

tagA Tag object to search in.
ownerA string specifying the owner to match.
createA bool specifying whether or not to create and add a new frame to the tag if a match is not found.
A PrivateFrame object containing the matching frame, or if a match wasn't found and create is .

Definition at line 325 of file PrivateFrame.cs.

                  PrivateFrame priv;
                  foreach (Frame frame in tag.GetFrames (FrameType.PRIV)) {
                        priv = frame as PrivateFrame;
                        if (priv != null && priv.Owner == owner)
                              return priv;
                  if (!create)
                        return null;
                  priv = new PrivateFrame (owner);
                  tag.AddFrame (priv);
                  return priv;

Generated by  Doxygen 1.6.0   Back to index