本文整理汇总了Java中java.io.ObjectOutput.writeFloat方法的典型用法代码示例。如果您正苦于以下问题:Java ObjectOutput.writeFloat方法的具体用法?Java ObjectOutput.writeFloat怎么用?Java ObjectOutput.writeFloat使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类java.io.ObjectOutput
的用法示例。
在下文中一共展示了ObjectOutput.writeFloat方法的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 1 );
// SUPER
super.writeExternal( out );
// NUMBER OF ENTRIES
out.writeInt( _size );
// LOAD FACTOR -- Added version 1
out.writeFloat( _loadFactor );
// NO ENTRY VALUE -- Added version 1
out.writeShort( no_entry_value );
// ENTRIES
for ( int i = _states.length; i-- > 0; ) {
if ( _states[i] == FULL ) {
out.writeShort( _set[i] );
}
}
}
示例2: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 0 );
// POSITION
out.writeInt( _pos );
// NO_ENTRY_VALUE
out.writeFloat( no_entry_value );
// ENTRIES
int len = _data.length;
out.writeInt( len );
for( int i = 0; i < len; i++ ) {
out.writeFloat( _data[ i ] );
}
}
示例3: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 1 );
// SUPER
super.writeExternal( out );
// NUMBER OF ENTRIES
out.writeInt( _size );
// LOAD FACTOR -- Added version 1
out.writeFloat( _loadFactor );
// NO ENTRY VALUE -- Added version 1
out.writeDouble( no_entry_value );
// ENTRIES
for ( int i = _states.length; i-- > 0; ) {
if ( _states[i] == FULL ) {
out.writeDouble( _set[i] );
}
}
}
示例4: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 1 );
// SUPER
super.writeExternal( out );
// NUMBER OF ENTRIES
out.writeInt( _size );
// LOAD FACTOR -- Added version 1
out.writeFloat( _loadFactor );
// NO ENTRY VALUE -- Added version 1
out.writeLong( no_entry_value );
// ENTRIES
for ( int i = _states.length; i-- > 0; ) {
if ( _states[i] == FULL ) {
out.writeLong( _set[i] );
}
}
}
示例5: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 1 );
// SUPER
super.writeExternal( out );
// NUMBER OF ENTRIES
out.writeInt( _size );
// LOAD FACTOR -- Added version 1
out.writeFloat( _loadFactor );
// NO ENTRY VALUE -- Added version 1
out.writeFloat( no_entry_value );
// ENTRIES
for ( int i = _states.length; i-- > 0; ) {
if ( _states[i] == FULL ) {
out.writeFloat( _set[i] );
}
}
}
示例6: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 1 );
// SUPER
super.writeExternal( out );
// NUMBER OF ENTRIES
out.writeInt( _size );
// LOAD FACTOR -- Added version 1
out.writeFloat( _loadFactor );
// NO ENTRY VALUE -- Added version 1
out.writeChar( no_entry_value );
// ENTRIES
for ( int i = _states.length; i-- > 0; ) {
if ( _states[i] == FULL ) {
out.writeChar( _set[i] );
}
}
}
示例7: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 0 );
// SUPER
super.writeExternal( out );
// NO_ENTRY_KEY
out.writeLong( no_entry_key );
// NO_ENTRY_VALUE
out.writeFloat( no_entry_value );
}
示例8: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 0 );
// SUPER
super.writeExternal( out );
// NO_ENTRY_KEY
out.writeFloat( no_entry_key );
// NO_ENTRY_VALUE
out.writeChar( no_entry_value );
}
示例9: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 0 );
// SUPER
super.writeExternal( out );
// NO_ENTRY_KEY
out.writeFloat( no_entry_key );
// NO_ENTRY_VALUE
out.writeShort( no_entry_value );
}
示例10: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 0 );
// SUPER
super.writeExternal( out );
// NO_ENTRY_KEY
out.writeFloat( no_entry_key );
// NO_ENTRY_VALUE
out.writeDouble( no_entry_value );
}
示例11: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
public void writeExternal(ObjectOutput out) throws IOException {
out.writeBoolean(z);
out.writeByte(b);
out.writeChar(c);
out.writeShort(s);
out.writeInt(i);
out.writeFloat(f);
out.writeLong(j);
out.writeDouble(d);
out.writeObject(str);
out.writeObject(parent);
out.writeObject(left);
out.writeObject(right);
}
示例12: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 0 );
// SUPER
super.writeExternal( out );
// NO_ENTRY_KEY
out.writeByte( no_entry_key );
// NO_ENTRY_VALUE
out.writeFloat( no_entry_value );
}
示例13: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void writeExternal( ObjectOutput out ) throws IOException {
// VERSION
out.writeByte( 0 );
// SUPER
super.writeExternal( out );
// NO_ENTRY_KEY
out.writeFloat( no_entry_key );
// NO_ENTRY_VALUE
out.writeFloat( no_entry_value );
}
示例14: writeExternal
import java.io.ObjectOutput; //导入方法依赖的package包/类
/**
* <code>writeExternal</code> writes this quaternion out to a
* <code>ObjectOutput</code> object. NOTE: Used with serialization. Not to
* be called manually.
*
* @param out
* the object to write to.
* @throws IOException
* if writing to the ObjectOutput fails.
* @see java.io.Externalizable
*/
public void writeExternal(ObjectOutput out) throws IOException {
out.writeFloat(x);
out.writeFloat(y);
out.writeFloat(z);
out.writeFloat(w);
}