Defines | Typedefs

nsLiteralString.h File Reference

#include "nscore.h"
#include "nsDependentString.h"
Include dependency graph for nsLiteralString.h:
This graph shows which files directly or indirectly include this file:

Defines

#define NS_LL(s)   L##s
#define NS_MULTILINE_LITERAL_STRING(s)   nsDependentString(reinterpret_cast<const nsAString::char_type*>(s), PRUint32((sizeof(s)/2)-1))
#define NS_MULTILINE_LITERAL_STRING_INIT(n, s)   n(reinterpret_cast<const nsAString::char_type*>(s), PRUint32((sizeof(s)/2)-1))
#define NS_NAMED_MULTILINE_LITERAL_STRING(n, s)   const nsDependentString n(reinterpret_cast<const nsAString::char_type*>(s), PRUint32((sizeof(s)/2)-1))
#define NS_L(s)   NS_LL(s)
#define NS_LITERAL_STRING(s)   static_cast<const nsAFlatString&>(NS_MULTILINE_LITERAL_STRING(NS_LL(s)))
#define NS_LITERAL_STRING_INIT(n, s)   NS_MULTILINE_LITERAL_STRING_INIT(n, NS_LL(s))
#define NS_NAMED_LITERAL_STRING(n, s)   NS_NAMED_MULTILINE_LITERAL_STRING(n, NS_LL(s))
#define NS_LITERAL_CSTRING(s)   static_cast<const nsDependentCString&>(nsDependentCString(s, PRUint32(sizeof(s)-1)))
#define NS_LITERAL_CSTRING_INIT(n, s)   n(s, PRUint32(sizeof(s)-1))
#define NS_NAMED_LITERAL_CSTRING(n, s)   const nsDependentCString n(s, PRUint32(sizeof(s)-1))

Typedefs

typedef nsDependentString nsLiteralString
typedef nsDependentCString nsLiteralCString

Define Documentation

#define NS_L (   s  )     NS_LL(s)
#define NS_LITERAL_CSTRING (   s  )     static_cast<const nsDependentCString&>(nsDependentCString(s, PRUint32(sizeof(s)-1)))
#define NS_LITERAL_CSTRING_INIT (   n,
  s 
)    n(s, PRUint32(sizeof(s)-1))
#define NS_LITERAL_STRING (   s  )     static_cast<const nsAFlatString&>(NS_MULTILINE_LITERAL_STRING(NS_LL(s)))
#define NS_LITERAL_STRING_INIT (   n,
  s 
)    NS_MULTILINE_LITERAL_STRING_INIT(n, NS_LL(s))
#define NS_LL (   s  )     L##s
#define NS_MULTILINE_LITERAL_STRING (   s  )     nsDependentString(reinterpret_cast<const nsAString::char_type*>(s), PRUint32((sizeof(s)/2)-1))
#define NS_MULTILINE_LITERAL_STRING_INIT (   n,
  s 
)    n(reinterpret_cast<const nsAString::char_type*>(s), PRUint32((sizeof(s)/2)-1))
#define NS_NAMED_LITERAL_CSTRING (   n,
  s 
)    const nsDependentCString n(s, PRUint32(sizeof(s)-1))
#define NS_NAMED_LITERAL_STRING (   n,
  s 
)    NS_NAMED_MULTILINE_LITERAL_STRING(n, NS_LL(s))
#define NS_NAMED_MULTILINE_LITERAL_STRING (   n,
  s 
)    const nsDependentString n(reinterpret_cast<const nsAString::char_type*>(s), PRUint32((sizeof(s)/2)-1))

Typedef Documentation

typedef nsDependentCString nsLiteralCString
typedef nsDependentString nsLiteralString