endianorder.html

来自「这个是java的quicktime for java 的详细使用文档」· HTML 代码 · 共 765 行 · 第 1/3 页

HTML
765
字号
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc on Mon Jul 15 11:51:03 PDT 2002 --><TITLE>: Class  EndianOrder</TITLE><LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style"></HEAD><BODY BGCOLOR="white"><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_top"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/EndianOrder.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../quicktime/util/EndianFlipSpec.html"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../quicktime/util/IntEncodedImage.html"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="EndianOrder.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: &nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">quicktime.util</FONT><BR>Class  EndianOrder</H2><PRE>java.lang.Object  |  +--<B>quicktime.util.EndianOrder</B></PRE><HR><DL><DT>public final class <B>EndianOrder</B><DT>extends java.lang.Object</DL><P>The endian methods in this class are context sensitive, in that the big-endian methods will only flip if the current platform is little endian and the little-endian methods will only flip if the current platform is big endian. <P> The names of the methods are provided as a means of documenting the usage of the method itself. To operate as specified they rely upon the application correctly providing the expected endian-ordered number to the method. Thus, the flipNativeToBigEndian and flipBigEndianToNative will both flip when executed on a little-endian architecture but the methods are unable to determine if the argument is actually (in this case) in native little-endian order or big endian order. The application itself must ensure that the provided argument is correct for these methods to return their exepcted result. <P><P><HR><P><!-- ======== INNER CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><!-- ======== CONSTRUCTOR SUMMARY ======== --><!-- ========== METHOD SUMMARY =========== --><A NAME="method_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Method Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipBigEndianToNative(java.lang.Object, int, quicktime.util.EndianDescriptor)">flipBigEndianToNative</A></B>(java.lang.Object&nbsp;src,                      int&nbsp;srcOffset,                      <A HREF="../../quicktime/util/EndianDescriptor.html">EndianDescriptor</A>&nbsp;ed)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip, iff the current runtime architecture is <B>little endian</B>, the supplied src object's fields according to the characteristics of the supplied EndianDescriptor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipBigEndianToNative(java.lang.Object, int, java.lang.Object, int, quicktime.util.EndianDescriptor)">flipBigEndianToNative</A></B>(java.lang.Object&nbsp;src,                      int&nbsp;srcOffset,                      java.lang.Object&nbsp;dest,                      int&nbsp;destOffset,                      <A HREF="../../quicktime/util/EndianDescriptor.html">EndianDescriptor</A>&nbsp;ed)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip, iff the current runtime architecture is <B>little endian</B>, the supplied src object's fields according to the characteristics of the supplied EndianDescriptor and copy these flipped values to the destination object.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;short</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipBigEndianToNative16(short)">flipBigEndianToNative16</A></B>(short&nbsp;s)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 16bit value iff the current runtime architecture is <B>little endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipBigEndianToNative32(int)">flipBigEndianToNative32</A></B>(int&nbsp;i)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 32bit value iff the current runtime architecture is <B>little endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;long</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipBigEndianToNative64(long)">flipBigEndianToNative64</A></B>(long&nbsp;l)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 64bit value iff the current runtime architecture is <B>little endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipLittleEndianToNative(java.lang.Object, int, quicktime.util.EndianDescriptor)">flipLittleEndianToNative</A></B>(java.lang.Object&nbsp;src,                         int&nbsp;srcOffset,                         <A HREF="../../quicktime/util/EndianDescriptor.html">EndianDescriptor</A>&nbsp;ed)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip, iff the current runtime architecture is <B>big endian</B>, the supplied src object's fields according to the characteristics of the supplied EndianDescriptor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipLittleEndianToNative(java.lang.Object, int, java.lang.Object, int, quicktime.util.EndianDescriptor)">flipLittleEndianToNative</A></B>(java.lang.Object&nbsp;src,                         int&nbsp;srcOffset,                         java.lang.Object&nbsp;dest,                         int&nbsp;destOffset,                         <A HREF="../../quicktime/util/EndianDescriptor.html">EndianDescriptor</A>&nbsp;ed)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip, iff the current runtime architecture is <B>big endian</B>, the supplied src object's fields according to the characteristics of the supplied EndianDescriptor and copy these flipped values to the destination object.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;short</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipLittleEndianToNative16(short)">flipLittleEndianToNative16</A></B>(short&nbsp;s)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 16bit value iff the current runtime architecture is <B>big endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipLittleEndianToNative32(int)">flipLittleEndianToNative32</A></B>(int&nbsp;i)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 32bit value iff the current runtime architecture is <B>big endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;long</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipLittleEndianToNative64(long)">flipLittleEndianToNative64</A></B>(long&nbsp;l)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 64bit value iff the current runtime architecture is <B>big endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipNativeToBigEndian(java.lang.Object, int, quicktime.util.EndianDescriptor)">flipNativeToBigEndian</A></B>(java.lang.Object&nbsp;src,                      int&nbsp;srcOffset,                      <A HREF="../../quicktime/util/EndianDescriptor.html">EndianDescriptor</A>&nbsp;ed)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip iff the current runtime architecture is <B>little endian</B> the supplied src object's fields according to the characteristics of the supplied EndianDescriptor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipNativeToBigEndian(java.lang.Object, int, java.lang.Object, int, quicktime.util.EndianDescriptor)">flipNativeToBigEndian</A></B>(java.lang.Object&nbsp;src,                      int&nbsp;srcOffset,                      java.lang.Object&nbsp;dest,                      int&nbsp;destOffset,                      <A HREF="../../quicktime/util/EndianDescriptor.html">EndianDescriptor</A>&nbsp;ed)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip, iff the current runtime architecture is <B>little endian</B>, the supplied src object's fields according to the characteristics of the supplied EndianDescriptor and copy these flipped values to the destination object.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;short</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipNativeToBigEndian16(short)">flipNativeToBigEndian16</A></B>(short&nbsp;s)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 16bit value iff the current runtime architecture is <B>little endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../quicktime/util/EndianOrder.html#flipNativeToBigEndian32(int)">flipNativeToBigEndian32</A></B>(int&nbsp;i)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This will flip the endian order of a 32bit value iff the current runtime architecture is <B>little endian</B>, otherwise the returned value is the same as the supplied value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor">

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?