File: ea03_006.adb

package info (click to toggle)
libxmlada 25.0.0-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 11,212 kB
  • sloc: ada: 78,068; sh: 3,310; makefile: 394; xml: 111; python: 39
file content (19 lines) | stat: -rw-r--r-- 504 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
with DOM.Core; use DOM.Core;
with DOM.Core.Documents; use DOM.Core.Documents;
with DOM.Core.Elements;  use DOM.Core.Elements;
with DOM.Core.Nodes;     use DOM.Core.Nodes;

procedure EA03_006 is
   Impl : DOM_Implementation;
   Doc : Document;
   Child, Element : Node;
   pragma Unreferenced (Child);
begin
   Doc := Create_Document (Impl);

   Element := Create_Element (Doc, "myelem");
   Set_Attribute (Element, "id", "42");
   Child := Append_Child (Doc, Element);

   Print (Element);
end EA03_006;