comp.lang.ada
 help / color / mirror / Atom feed
* integer or string to unbounded_string?
@ 2003-01-28 21:52 Bjoern Schiessle
  2003-01-28 22:30 ` Stephen Leake
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Bjoern Schiessle @ 2003-01-28 21:52 UTC (permalink / raw)


Hello,
i need to convert a integer to unbounded_string. I have found the
function integer'image() but this function gives me an string. How can i
convert this string to unbounded string or directly integer to
unbounded_string?

Thanks a lot!
Bjoern



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: integer or string to unbounded_string?
  2003-01-28 21:52 integer or string to unbounded_string? Bjoern Schiessle
@ 2003-01-28 22:30 ` Stephen Leake
  2003-01-28 22:36 ` chris.danx
  2003-01-28 23:00 ` Bobby D. Bryant
  2 siblings, 0 replies; 4+ messages in thread
From: Stephen Leake @ 2003-01-28 22:30 UTC (permalink / raw)


Bjoern Schiessle <devnull@schiessle.org> writes:

> Hello,
> i need to convert a integer to unbounded_string. I have found the
> function integer'image() but this function gives me an string. How can i
> convert this string to unbounded string or directly integer to
> unbounded_string?

See the standard package Ada.Strings.Unbounded.

-- 
-- Stephe



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: integer or string to unbounded_string?
  2003-01-28 21:52 integer or string to unbounded_string? Bjoern Schiessle
  2003-01-28 22:30 ` Stephen Leake
@ 2003-01-28 22:36 ` chris.danx
  2003-01-28 23:00 ` Bobby D. Bryant
  2 siblings, 0 replies; 4+ messages in thread
From: chris.danx @ 2003-01-28 22:36 UTC (permalink / raw)


Bjoern Schiessle wrote:
> Hello,
> i need to convert a integer to unbounded_string. I have found the
> function integer'image() but this function gives me an string. How can i
> convert this string to unbounded string or directly integer to
> unbounded_string?

 From memory,

to_unbounded_string (Integer'image(x))

I'm not sure about this, so you'd have to look unbounded string in the 
RM to be sure

http://www.ada-auth.org/~acats/arm.html


hey, what am I thinking? I can do that now...

http://www.adaic.org/standards/95lrm/html/RM-A-4-5.html

look at 9, it is the function which returns an unbounded string from a 
string.


HTH,
Chris




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: integer or string to unbounded_string?
  2003-01-28 21:52 integer or string to unbounded_string? Bjoern Schiessle
  2003-01-28 22:30 ` Stephen Leake
  2003-01-28 22:36 ` chris.danx
@ 2003-01-28 23:00 ` Bobby D. Bryant
  2 siblings, 0 replies; 4+ messages in thread
From: Bobby D. Bryant @ 2003-01-28 23:00 UTC (permalink / raw)


On Tue, 28 Jan 2003 22:52:26 +0100, Bjoern Schiessle wrote:

> Hello,
> i need to convert a integer to unbounded_string. I have found the
> function integer'image() but this function gives me an string. How can i
> convert this string to unbounded string or directly integer to
> unbounded_string?

To_Unbounded_String( Integer'Image( Whatever ) )

-- 
Bobby Bryant
Austin, Texas




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2003-01-28 23:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-01-28 21:52 integer or string to unbounded_string? Bjoern Schiessle
2003-01-28 22:30 ` Stephen Leake
2003-01-28 22:36 ` chris.danx
2003-01-28 23:00 ` Bobby D. Bryant

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox