Book a Demo

Author Topic: Return EA Types Information  (Read 4414 times)

scs

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Return EA Types Information
« on: October 21, 2009, 03:16:22 am »
Hi,

I would like to return EA types information (from t_objecttypes and t_diagramtypes) using API Automation or another way in C#.

Someone knows how to do this?

Thanks!

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Return EA Types Information
« Reply #1 on: October 21, 2009, 04:51:13 pm »
Can you maybe provide some more information on what exactly you are trying to achieve?
I'm happy to help but I don't understand what you are trying to do.

Geert

scs

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Return EA Types Information
« Reply #2 on: October 21, 2009, 10:12:21 pm »
Hi,
The EA has some element types like Action, Activity, Actor, Artifact, Association, Change, etc. and diagram types like Analysis Diagram, Use Case Diagram, Class Diagram, etc.

This information is default in the EA and stay registered on EA’s table t_objecttypes and t_diagramtypes.

One example this information on EA is found in the treeview  "EA / Settings / General Types / Status / Applies to"

I would like to recover this information (element types and diagram types) using some API.

Thanks!

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Return EA Types Information
« Reply #3 on: October 21, 2009, 10:58:19 pm »
I don't think this information is readily available, but you can always use the operation "Repository.SQLQuery (string SQL)".
That will give you anything you want from the current database in an xml format.

Geert

Aaron B

  • EA Administrator
  • EA User
  • *****
  • Posts: 941
  • Karma: +18/-0
    • View Profile
Re: Return EA Types Information
« Reply #4 on: October 22, 2009, 09:14:16 am »
Try using Repository.GetReferenceList().  Each reference list simply contains a simple collection of strings.  For example:

Code: [Select]
Set References = GetReferenceList("Element")
For i = 0 To References.Count - 1
      s = s & References.GetAt(i) & ";"
Next

See API documentation for GetReferenceList() on the Repository page.
« Last Edit: October 22, 2009, 09:15:32 am by AaronB »

scs

  • EA Novice
  • *
  • Posts: 15
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Return EA Types Information
« Reply #5 on: October 22, 2009, 09:29:36 pm »
Hi,

Thanks very much for information.

 :)