ドキュメント

API/1.3/Utilities

From jQuery JavaScript Library

(Redirected from Utilities)
Jump to: navigation, search

NameType
Browser and Feature Detection:
NameType
jQuery.supportReturns: Object
Added in jQuery 1.3 A collection of properties that represent the presence of different browser features or bugs.
jQuery.browserReturns: Map
We recommend against using this property, please try to use feature detection instead (see jQuery.support). Contains flags for the useragent, read from navigator.userAgent. While jQuery.browser will not be removed from future versions of jQuery, every effort to use jQuery.support and proper feature detection should be made.
jQuery.browser.versionReturns: String
Deprecated in jQuery 1.3 (see jQuery.support) The version number of the rendering engine for the user's browser.
jQuery.boxModelReturns: Boolean
Deprecated in jQuery 1.3 (see jQuery.support) States if the current page, in the user's browser, is being rendered using the W3C CSS Box Model.
Array and Object operations:
NameType
jQuery.each( object, callback )Returns: Object
A generic iterator function, which can be used to seamlessly iterate over both objects and arrays. Arrays and array-like objects with a length property (such as a function's arguments object) are iterated by numeric index, from 0 to length-1. Other objects are iterated via their named properties.
jQuery.extend( deep, target, object1, objectN )Returns: Object
Extend one object with one or more others, returning the modified object.
jQuery.grep( array, callback, invert )Returns: Array
Finds the elements of an array which satisfy a filter function. The original array is not affected.
jQuery.makeArray( obj )Returns: Array
Turns anything into a true array.
jQuery.map( array, callback )Returns: Array
Translate all items in an array to another array of items.
jQuery.inArray( value, array )Returns: Number
Determine the index of the first parameter in the Array (-1 if not found).
jQuery.merge( first, second )Returns: Array
Merge two arrays together.
jQuery.unique( array )Returns: Array
Remove all duplicate elements from an array of elements. Note that this only works on arrays of DOM elements, not strings or numbers.
Test operations:
NameType
jQuery.isArray( obj )Returns: boolean
Added in jQuery 1.3 Determine if the parameter passed is an array.
jQuery.isFunction( obj )Returns: boolean
Determine if the parameter passed is a Javascript function object.
String operations:
NameType
jQuery.trim( str )Returns: String
Remove the whitespace from the beginning and end of a string.
URLs:
NameType
jQuery.param( obj )Returns: String
Serializes an array of form elements or an object (core of .serialize() method).