Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

21. Score File Support > Creating a UniFileLoader and MultiDataObject for *.sco...

Creating a UniFileLoader and MultiDataObject for *.score Files

Now that the infrastructure of the Minicomposer module is ready, we will begin to make it really do something.

The first order of business is to recognize *.score files as meaningful in the IDE. While most of this is “boilerplate” code, several classes and setting files are involved, and it is worth examining each of them because we will need to understand and customize the code later on.

The basic hook the module adds to the IDE is a data loader that is tuned to notice score files and provide data objects that the IDE can interact with. We will make this data loader sensitive to file MIME type, rather than directly looking for a particular file extension. The first step is to define a MIME type for score files, meaning that the IDE understands that the files are in a certain format distinct from other text or binary files. The score file format is invented for this example and there is not a standard MIME type for it, so we will create one, text/x-minicomposer-score.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint