コード例 #1
0
ファイル: RiffStaff.cs プロジェクト: svejdo1/niffty
        /** Peek into the parentInput's input stream and if the next item
         * is a NIFF staff, return a new Staff.  Otherwise,
         * return null and leave the input stream unchanged.
         *
         * @param parentInput    the parent RIFF object being used to read the input stream
         */
        public static Staff maybeNew(Riff parentInput)
        {
            if (!parentInput.peekListID().Equals(RIFF_ID))
            return null;

              return newInstance(parentInput);
        }
コード例 #2
0
        /** Peek into the parentInput's input stream and if the next item
         * is a NIFF system, return a new StaffSystem.  Otherwise,
         * return null and leave the input stream unchanged.
         *
         * @param parentInput    the parent RIFF object being used to read the input stream
         */
        static public StaffSystem maybeNew(Riff parentInput)
        {
            if (!parentInput.peekListID().Equals(RIFF_ID))
            {
                return(null);
            }

            return(newInstance(parentInput));
        }