2007-11-06 12:13:52 +00:00
< html >
< head >
2009-12-11 21:01:22 +00:00
< meta http-equiv = "Content-Type" content = "text/html; charset=US-ASCII" >
2007-11-06 12:13:52 +00:00
< title > is_sequence</ title >
2010-07-04 19:20:50 +00:00
< link rel = "stylesheet" href = "../../../../../../doc/src/boostbook.css" type = "text/css" >
< meta name = "generator" content = "DocBook XSL Stylesheets V1.75.2" >
2009-12-11 21:01:22 +00:00
< link rel = "home" href = "../../index.html" title = "Chapter 1. Fusion 2.0" >
2007-11-06 12:13:52 +00:00
< link rel = "up" href = "../support.html" title = "Support" >
2009-09-25 00:21:53 +00:00
< link rel = "prev" href = "../support.html" title = "Support" >
2007-11-06 12:13:52 +00:00
< link rel = "next" href = "is_view.html" title = "is_view" >
</ head >
< body bgcolor = "white" text = "black" link = "#0000FF" vlink = "#840084" alink = "#0000FF" >
< table cellpadding = "2" width = "100%" >< tr >
< td valign = "top" >< img alt = "Boost C++ Libraries" width = "277" height = "86" src = "../../../../../../boost.png" ></ td >
2008-07-17 23:59:22 +00:00
< td align = "center" >< a href = "../../../../../../index.html" > Home</ a ></ td >
2010-07-04 19:20:50 +00:00
< td align = "center" >< a href = "../../../../../../libs/libraries.htm" > Libraries</ a ></ td >
2008-07-17 23:59:22 +00:00
< td align = "center" >< a href = "http://www.boost.org/users/people.html" > People</ a ></ td >
< td align = "center" >< a href = "http://www.boost.org/users/faq.html" > FAQ</ a ></ td >
2007-11-06 12:13:52 +00:00
< td align = "center" >< a href = "../../../../../../more/index.htm" > More</ a ></ td >
</ tr ></ table >
< hr >
< div class = "spirit-nav" >
2010-07-04 19:20:50 +00:00
< a accesskey = "p" href = "../support.html" >< img src = "../../../../../../doc/src/images/prev.png" alt = "Prev" ></ a >< a accesskey = "u" href = "../support.html" >< img src = "../../../../../../doc/src/images/up.png" alt = "Up" ></ a >< a accesskey = "h" href = "../../index.html" >< img src = "../../../../../../doc/src/images/home.png" alt = "Home" ></ a >< a accesskey = "n" href = "is_view.html" >< img src = "../../../../../../doc/src/images/next.png" alt = "Next" ></ a >
2007-11-06 12:13:52 +00:00
</ div >
2010-06-03 08:29:23 +00:00
< div class = "section" >
2009-09-25 00:21:53 +00:00
< div class = "titlepage" >< div >< div >< h3 class = "title" >
< a name = "fusion.support.is_sequence" ></ a >< a class = "link" href = "is_sequence.html" title = "is_sequence" > is_sequence</ a >
</ h3 ></ div ></ div ></ div >
< a name = "fusion.support.is_sequence.description" ></ a >< h5 >
2011-07-08 19:42:35 +00:00
< a name = "fusion.support.is_sequence.description-heading" ></ a >
2009-09-25 00:21:53 +00:00
< a class = "link" href = "is_sequence.html#fusion.support.is_sequence.description" > Description</ a >
</ h5 >
2007-11-06 12:13:52 +00:00
< p >
2009-09-25 00:21:53 +00:00
Metafunction that evaluates to < code class = "computeroutput" >< span class = "identifier" > mpl</ span >< span class = "special" > ::</ span >< span class = "identifier" > true_</ span ></ code >
if a certain type < code class = "computeroutput" >< span class = "identifier" > T</ span ></ code > is a
conforming Fusion < a class = "link" href = "../sequence.html" title = "Sequence" > Sequence</ a > , < code class = "computeroutput" >< span class = "identifier" > mpl</ span >< span class = "special" > ::</ span >< span class = "identifier" > false_</ span ></ code >
2007-11-06 12:13:52 +00:00
otherwise. This may be specialized to accomodate clients which provide Fusion
conforming sequences.
</ p >
2009-09-25 00:21:53 +00:00
< a name = "fusion.support.is_sequence.synopsis" ></ a >< h5 >
2011-07-08 19:42:35 +00:00
< a name = "fusion.support.is_sequence.synopsis-heading" ></ a >
2009-09-25 00:21:53 +00:00
< a class = "link" href = "is_sequence.html#fusion.support.is_sequence.synopsis" > Synopsis</ a >
</ h5 >
2009-02-22 06:27:12 +00:00
< pre class = "programlisting" >< span class = "keyword" > namespace</ span > < span class = "identifier" > traits</ span >
2007-11-06 12:13:52 +00:00
< span class = "special" > {</ span >
< span class = "keyword" > template</ span > < span class = "special" > < </ span >< span class = "keyword" > typename</ span > < span class = "identifier" > T</ span >< span class = "special" > > </ span >
2007-11-07 02:12:28 +00:00
< span class = "keyword" > struct</ span > < span class = "identifier" > is_sequence</ span >
2007-11-06 12:13:52 +00:00
< span class = "special" > {</ span >
< span class = "keyword" > typedef</ span > < span class = "emphasis" >< em > unspecified</ em ></ span > < span class = "identifier" > type</ span >< span class = "special" > ;</ span >
< span class = "special" > };</ span >
< span class = "special" > }</ span >
</ pre >
2009-09-25 00:21:53 +00:00
< a name = "fusion.support.is_sequence.parameters" ></ a >< h5 >
2011-07-08 19:42:35 +00:00
< a name = "fusion.support.is_sequence.parameters-heading" ></ a >
2009-09-25 00:21:53 +00:00
< a class = "link" href = "is_sequence.html#fusion.support.is_sequence.parameters" > Parameters</ a >
</ h5 >
2007-11-06 12:13:52 +00:00
< div class = "informaltable" >< table class = "table" >
< colgroup >
< col >
< col >
< col >
</ colgroup >
< thead >< tr >
2009-09-25 00:21:53 +00:00
< th >
2010-04-10 18:55:44 +00:00
< p >
Parameter
</ p >
2009-09-25 00:21:53 +00:00
</ th >
< th >
2010-04-10 18:55:44 +00:00
< p >
Requirement
</ p >
2009-09-25 00:21:53 +00:00
</ th >
< th >
2010-04-10 18:55:44 +00:00
< p >
Description
</ p >
2009-09-25 00:21:53 +00:00
</ th >
2007-11-06 12:13:52 +00:00
</ tr ></ thead >
< tbody >< tr >
2009-09-25 00:21:53 +00:00
< td >
2010-04-10 18:55:44 +00:00
< p >
< code class = "computeroutput" >< span class = "identifier" > T</ span ></ code >
</ p >
2009-09-25 00:21:53 +00:00
</ td >
< td >
2010-04-10 18:55:44 +00:00
< p >
Any type
</ p >
2009-09-25 00:21:53 +00:00
</ td >
< td >
2010-04-10 18:55:44 +00:00
< p >
The type to query.
</ p >
2009-09-25 00:21:53 +00:00
</ td >
2007-11-06 12:13:52 +00:00
</ tr ></ tbody >
</ table ></ div >
2009-09-25 00:21:53 +00:00
< a name = "fusion.support.is_sequence.expression_semantics" ></ a >< h5 >
2011-07-08 19:42:35 +00:00
< a name = "fusion.support.is_sequence.expression_semantics-heading" ></ a >
2009-09-25 00:21:53 +00:00
< a class = "link" href = "is_sequence.html#fusion.support.is_sequence.expression_semantics" > Expression
2007-11-06 12:13:52 +00:00
Semantics</ a >
2009-09-25 00:21:53 +00:00
</ h5 >
2009-02-22 06:27:12 +00:00
< pre class = "programlisting" >< span class = "keyword" > typedef</ span > < span class = "identifier" > traits</ span >< span class = "special" > ::</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > < </ span >< span class = "identifier" > T</ span >< span class = "special" > > ::</ span >< span class = "identifier" > type</ span > < span class = "identifier" > c</ span >< span class = "special" > ;</ span >
2007-11-06 12:13:52 +00:00
</ pre >
< p >
2009-09-25 00:21:53 +00:00
< span class = "bold" >< strong > Return type</ strong ></ span > : An < a href = "http://www.boost.org/libs/mpl/doc/refmanual/integral-constant.html" target = "_top" > MPL
2007-11-06 12:13:52 +00:00
Boolean Constant</ a > .
</ p >
< p >
2009-09-25 00:21:53 +00:00
< span class = "bold" >< strong > Semantics</ strong ></ span > : Metafunction that evaluates to
< code class = "computeroutput" >< span class = "identifier" > mpl</ span >< span class = "special" > ::</ span >< span class = "identifier" > true_</ span ></ code > if a certain type < code class = "computeroutput" >< span class = "identifier" > T</ span ></ code >
is a conforming Fusion sequence, < code class = "computeroutput" >< span class = "identifier" > mpl</ span >< span class = "special" > ::</ span >< span class = "identifier" > false_</ span ></ code >
2007-11-06 12:13:52 +00:00
otherwise.
</ p >
2009-09-25 00:21:53 +00:00
< a name = "fusion.support.is_sequence.header" ></ a >< h5 >
2011-07-08 19:42:35 +00:00
< a name = "fusion.support.is_sequence.header-heading" ></ a >
2009-09-25 00:21:53 +00:00
< a class = "link" href = "is_sequence.html#fusion.support.is_sequence.header" > Header</ a >
</ h5 >
2009-02-22 06:27:12 +00:00
< pre class = "programlisting" >< span class = "preprocessor" > #include</ span > < span class = "special" > < </ span >< span class = "identifier" > boost</ span >< span class = "special" > /</ span >< span class = "identifier" > fusion</ span >< span class = "special" > /</ span >< span class = "identifier" > support</ span >< span class = "special" > /</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > .</ span >< span class = "identifier" > hpp</ span >< span class = "special" > > </ span >
2007-11-06 12:13:52 +00:00
< span class = "preprocessor" > #include</ span > < span class = "special" > < </ span >< span class = "identifier" > boost</ span >< span class = "special" > /</ span >< span class = "identifier" > fusion</ span >< span class = "special" > /</ span >< span class = "identifier" > include</ span >< span class = "special" > /</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > .</ span >< span class = "identifier" > hpp</ span >< span class = "special" > > </ span >
</ pre >
2009-09-25 00:21:53 +00:00
< a name = "fusion.support.is_sequence.example" ></ a >< h5 >
2011-07-08 19:42:35 +00:00
< a name = "fusion.support.is_sequence.example-heading" ></ a >
2009-09-25 00:21:53 +00:00
< a class = "link" href = "is_sequence.html#fusion.support.is_sequence.example" > Example</ a >
</ h5 >
2009-02-22 06:27:12 +00:00
< pre class = "programlisting" >< span class = "identifier" > BOOST_MPL_ASSERT_NOT</ span >< span class = "special" > ((</ span > < span class = "identifier" > traits</ span >< span class = "special" > ::</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > < </ span > < span class = "identifier" > std</ span >< span class = "special" > ::</ span >< span class = "identifier" > vector</ span >< span class = "special" > < </ span >< span class = "keyword" > int</ span >< span class = "special" > > </ span > < span class = "special" > > </ span > < span class = "special" > ));</ span >
2007-11-06 12:13:52 +00:00
< span class = "identifier" > BOOST_MPL_ASSERT_NOT</ span >< span class = "special" > ((</ span > < span class = "identifier" > is_sequence</ span >< span class = "special" > < </ span > < span class = "keyword" > int</ span > < span class = "special" > > </ span > < span class = "special" > ));</ span >
2009-09-25 00:21:53 +00:00
< span class = "identifier" > BOOST_MPL_ASSERT</ span >< span class = "special" > ((</ span > < span class = "identifier" > traits</ span >< span class = "special" > ::</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > < </ span >< a class = "link" href = "../container/list.html" title = "list" >< code class = "computeroutput" >< span class = "identifier" > list</ span ></ code ></ a >< span class = "special" > <> </ span > < span class = "special" > > </ span > < span class = "special" > ));</ span >
< span class = "identifier" > BOOST_MPL_ASSERT</ span >< span class = "special" > ((</ span > < span class = "identifier" > traits</ span >< span class = "special" > ::</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > < </ span >< a class = "link" href = "../container/list.html" title = "list" >< code class = "computeroutput" >< span class = "identifier" > list</ span ></ code ></ a >< span class = "special" > < </ span >< span class = "keyword" > int</ span >< span class = "special" > > </ span > < span class = "special" > > </ span > < span class = "special" > ));</ span >
< span class = "identifier" > BOOST_MPL_ASSERT</ span >< span class = "special" > ((</ span > < span class = "identifier" > traits</ span >< span class = "special" > ::</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > < </ span >< a class = "link" href = "../container/vector.html" title = "vector" >< code class = "computeroutput" >< span class = "identifier" > vector</ span ></ code ></ a >< span class = "special" > <> </ span > < span class = "special" > > </ span > < span class = "special" > ));</ span >
< span class = "identifier" > BOOST_MPL_ASSERT</ span >< span class = "special" > ((</ span > < span class = "identifier" > traits</ span >< span class = "special" > ::</ span >< span class = "identifier" > is_sequence</ span >< span class = "special" > < </ span >< a class = "link" href = "../container/vector.html" title = "vector" >< code class = "computeroutput" >< span class = "identifier" > vector</ span ></ code ></ a >< span class = "special" > < </ span >< span class = "keyword" > int</ span >< span class = "special" > > </ span > < span class = "special" > > </ span > < span class = "special" > ));</ span >
2007-11-06 12:13:52 +00:00
</ pre >
</ div >
< table xmlns:rev = "http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width = "100%" >< tr >
< td align = "left" ></ td >
2009-12-11 21:01:22 +00:00
< td align = "right" >< div class = "copyright-footer" > Copyright © 2001-2007 Joel de Guzman, Dan Marsden, Tobias
2007-11-07 02:12:28 +00:00
Schwinger< p >
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at < a href = "http://www.boost.org/LICENSE_1_0.txt" target = "_top" > http://www.boost.org/LICENSE_1_0.txt</ a > )
2007-11-14 10:17:09 +00:00
</ p >
</ div ></ td >
2007-11-06 12:13:52 +00:00
</ tr ></ table >
< hr >
< div class = "spirit-nav" >
2010-07-04 19:20:50 +00:00
< a accesskey = "p" href = "../support.html" >< img src = "../../../../../../doc/src/images/prev.png" alt = "Prev" ></ a >< a accesskey = "u" href = "../support.html" >< img src = "../../../../../../doc/src/images/up.png" alt = "Up" ></ a >< a accesskey = "h" href = "../../index.html" >< img src = "../../../../../../doc/src/images/home.png" alt = "Home" ></ a >< a accesskey = "n" href = "is_view.html" >< img src = "../../../../../../doc/src/images/next.png" alt = "Next" ></ a >
2007-11-06 12:13:52 +00:00
</ div >
</ body >
</ html >