Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
StarUML Evológica Plugin
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
evologica
StarUML Evológica Plugin
Commits
d36b4459
Commit
d36b4459
authored
Jun 14, 2019
by
Sandro Camata Santana
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Ajustes para compatibilização Linux
parent
1f872ceb
Changes
20
Show whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
3530 additions
and
1141 deletions
+3530
-1141
CurioAddIn.dpr
EvoUMLPlugin/src/CurioAddIn.dpr
+25
-3
DelphiAddInObj.pas
EvoUMLPlugin/src/DelphiAddInObj.pas
+82
-73
InstantTextFiler.pas
EvoUMLPlugin/src/InstantCode/InstantTextFiler.pas
+0
-4
IntegracaoDelphiSUML.pas
EvoUMLPlugin/src/IntegracaoDelphiSUML.pas
+66
-304
fCodeGen.dfm
EvoUMLPlugin/src/fCodeGen.dfm
+69
-67
formMemo.dfm
EvoUMLPlugin/src/formMemo.dfm
+2242
-55
formMemo.pas
EvoUMLPlugin/src/formMemo.pas
+14
-7
ituDataBaseLogin.dfm
EvoUMLPlugin/src/ituDataBaseLogin.dfm
+129
-122
ituExplorerV2.dfm
EvoUMLPlugin/src/ituExplorerV2.dfm
+69
-63
ituExplorerV2.pas
EvoUMLPlugin/src/ituExplorerV2.pas
+3
-0
ituOQLExplorerV2.dfm
EvoUMLPlugin/src/ituOQLExplorerV2.dfm
+138
-67
ituOQLExplorerV2.pas
EvoUMLPlugin/src/ituOQLExplorerV2.pas
+343
-51
ituServiceParameters.dfm
EvoUMLPlugin/src/ituServiceParameters.dfm
+44
-44
ituServiceParameters.pas
EvoUMLPlugin/src/ituServiceParameters.pas
+22
-3
uCadastroCasoDeUso.dfm
EvoUMLPlugin/src/uCadastroCasoDeUso.dfm
+104
-110
uCadastroCasoDeUso.pas
EvoUMLPlugin/src/uCadastroCasoDeUso.pas
+34
-32
uCadastroCasoDeUsoIcones.dfm
EvoUMLPlugin/src/uCadastroCasoDeUsoIcones.dfm
+34
-30
uCadastroClasse.dfm
EvoUMLPlugin/src/uCadastroClasse.dfm
+73
-70
uCadastroClasse.pas
EvoUMLPlugin/src/uCadastroClasse.pas
+14
-11
uDBAttributeParameters.dfm
EvoUMLPlugin/src/uDBAttributeParameters.dfm
+25
-25
No files found.
EvoUMLPlugin/src/CurioAddIn.dpr
View file @
d36b4459
...
...
@@ -11,9 +11,12 @@ uses
cthreads,
{$ENDIF}{$ENDIF}
SysUtils,
LCLType,
Classes,
Interfaces,
{$IFDEF DARWIN}
CocoaInt,
{$ENDIF}
Forms,
acuObject,
utuMessage,
...
...
@@ -37,12 +40,26 @@ uses
utuXSD in 'utuXSD.pas',
DelphiAddInObj in 'DelphiAddInObj.pas';
type
{ ExceptionCatch }
ExceptionCatch= Class
public
procedure CustomExceptionHandler(Sender: TObject; E: Exception);
end;
exports
InitializeAddIn,
FinalizeAddIn,
DoMenuAction;
{$R *.res}
{ ExceptionCatch }
procedure ExceptionCatch.CustomExceptionHandler(Sender: TObject; E: Exception);
begin
Application.MessageBox(PChar(E.message), 'Error...', MB_ICONERROR or MB_OK);
end;
begin
ChangeLocaleFormatSetting;
...
...
@@ -50,13 +67,18 @@ begin
PersistenceManager.DefaultRepositoryClass := typeOf(acRepositorySQL);
PersistenceManager.RegisterClass(typeOf(acPersistentObject), acPersistentObjectClassFactory.Create);
gSQLDialectManager.RegisterSQLDialect('MS SQL Server', typeOf(acSQLDialectSQLServer), acSQLDialectSQLServerClassFactory.Create);
//
gSQLDialectManager.RegisterSQLDialect('Oracle', typeOf(acSQLDialectOracle), acSQLDialectOracleClassFactory.Create);
//
gSQLDialectManager.RegisterSQLDialect('DB2', typeOf(acSQLDialectDB2), acSQLDialectDB2ClassFactory.Create);
gSQLDialectManager.RegisterSQLDialect('Oracle', typeOf(acSQLDialectOracle), acSQLDialectOracleClassFactory.Create);
gSQLDialectManager.RegisterSQLDialect('DB2', typeOf(acSQLDialectDB2), acSQLDialectDB2ClassFactory.Create);
gLinksManager.RegisterLink('tcp/ip', typeOf(utLinkSock), utLinkSockClassFactory.Create);
{$IFDEF DARWIN}
MainPool := Nil;
{$ENDIF}
Application.Initialize;
Application.Scaled := True;
Application.OnException := ExceptionCatch.CustomExceptionHandler;
// Application.CaptureExceptions := True;
// ExtensionManager.LoadProfiles;
...
...
EvoUMLPlugin/src/DelphiAddInObj.pas
View file @
d36b4459
...
...
@@ -3,7 +3,7 @@ unit DelphiAddInObj;
interface
uses
LCLType
,
IntegracaoDelphiSUML
,
StarUMLintf
,
Classes
;
LCLType
,
IntegracaoDelphiSUML
,
StarUMLintf
,
cxuSession
,
Classes
;
type
...
...
@@ -40,7 +40,7 @@ type
procedure
ListOwnedClasses
(
piPackage
:
IUMLPackage
;
piObjectList
:
TInterfaceList
;
piStringList
:
TStringList
);
procedure
ListOwnedUseCases
(
piPackage
:
IUMLPackage
;
piObjectList
:
TInterfaceList
;
piStringList
:
TStringList
);
class
function
GetService
ConnectionString
:
string
;
class
function
GetService
Session
:
cxSession
;
class
function
DoMenuAction
(
const
ActionID
:
Integer
):
Integer
;
// function NotifyEvent(AEvent: EventKind): HResult; stdcall;
end
;
...
...
@@ -50,7 +50,8 @@ implementation
uses
InstantCode
,
SysUtils
,
Mostra_Processamento
,
utuStateMachine
,
fCodeGen
,
Controls
,
Forms
,
fModelMappingsGenerationOptions
,
fXSDEditor
,
ituDataBaseLogin
,
cxuSession
,
formMemo
,
fModelMappingsGenerationOptions
,
fXSDEditor
,
ituDataBaseLogin
,
formMemo
,
cxuCadastroClasse
,
cxuCadastroCasoDeUso
,
utuMessage
,
uCadastroCasoDeUso
,
uCadastroClasse
,
ituServiceParameters
,
ituExplorerV2
,
Registry
,
uRTFEditor
,
ituXSDExplorer
,
ituExportUnits
,
ituOQLExplorerV2
;
...
...
@@ -107,7 +108,7 @@ begin
result
:=
gStarUMLApp
.
SelectionManager
.
GetSelectedModelAt
(
0
);
end
;
class
function
TDelphiAddInObj
.
GetService
ConnectionString
:
string
;
class
function
TDelphiAddInObj
.
GetService
Session
:
cxSession
;
var
lServiceParamDialog
:
TitServiceParameters
;
lReg
:
TRegistry
;
begin
...
...
@@ -135,13 +136,10 @@ begin
gStarUMLApp
.
ProjectManager
.
Project
.
SetTaggedValueAsInteger
(
'DBMappings'
,
'ProjectMap'
,
'SystemCode'
,
lServiceParamDialog
.
SystemCode
);
gStarUMLApp
.
ProjectManager
.
Project
.
SetTaggedValueAsInteger
(
'DBMappings'
,
'ProjectMap'
,
'PortNumber'
,
lServiceParamDialog
.
PortNumber
);
result
:=
format
(
'ServerName=%s;PortNumber=%d;SystemCode=%d;UserName=%s;Password=%s;'
,
[
lServiceParamDialog
.
ServerName
,
lServiceParamDialog
.
PortNumber
,
lServiceParamDialog
.
SystemCode
,
lServiceParamDialog
.
UserName
,
lServiceParamDialog
.
Password
]);
result
:=
lServiceParamDialog
.
Session
;
end
else
result
:=
''
;
result
:=
Nil
;
finally
lReg
.
free
;
end
;
...
...
@@ -177,7 +175,6 @@ begin
on
E
:
Exception
do
begin
Application
.
MessageBox
(
PAnsiChar
(
e
.
Message
),
'Staruml'
,
MB_ICONERROR
);
raise
;
end
;
end
;
end
;
...
...
@@ -274,29 +271,32 @@ end;
class
procedure
TDelphiAddInObj
.
ActionMenu_InsertClass
;
var
lCadClasse
:
TCadastroClasse
;
lConnString
:
string
;
lSession
:
cxSession
;
lCadastroClasseUC
:
cxCadastroClasse
;
lModel
:
IModel
;
lUMLPackageAux
:
IUMLPackage
;
begin
lCadClasse
:=
nil
;
l
ConnString
:=
GetServiceConnectionString
;
if
lConnString
<>
''
then
l
Session
:=
GetServiceSession
;
if
Assigned
(
lSession
)
then
begin
lModel
:=
gStarUMLApp
.
SelectionManager
.
GetSelectedModelAt
(
0
);
lCadastroClasseUC
:=
cxCadastroClasse
.
Create
(
lSession
);
try
lCadClasse
:=
TCadastroClasse
.
Create
(
nil
,
lCadastroClasseUC
,
Nil
);
try
if
lModel
.
QueryInterface
(
IUMLPackage
,
lUMLPackageAux
)
=
S_OK
then
begin
lCadClasse
:=
TCadastroClasse
.
Create
(
nil
,
lConnString
,
Nil
);
lCadClasse
.
ClassPackage
:=
lModel
as
IUMLPackage
;
end
else
begin
lCadClasse
:=
TCadastroClasse
.
Create
(
nil
,
lConnString
,
Nil
);
end
;
if
lCadClasse
.
ShowModal
=
mrok
then
gStarUMLApp
.
SelectInModelExplorer
(
lCadClasse
.
UMLClass
);
finally
if
assigned
(
lCadClasse
)
then
lCadClasse
.
Free
;
lCadClasse
.
Free
;
end
;
finally
lCadastroClasseUC
.
Free
;
end
;
end
;
end
;
...
...
@@ -327,58 +327,66 @@ end;
class
procedure
TDelphiAddInObj
.
ActionMenu_EditClass
;
var
lCadClasse
:
TCadastroClasse
;
lConnString
:
string
;
lSession
:
cxSession
;
lCadastroClasseUC
:
cxCadastroClasse
;
lModel
:
IModel
;
lUMLClassAux
:
IUMLClass
;
begin
lCadClasse
:=
nil
;
lConnString
:=
GetServiceConnectionString
;
if
lConnString
<>
''
then
begin
lModel
:=
gStarUMLApp
.
SelectionManager
.
GetSelectedModelAt
(
0
);
if
lModel
.
QueryInterface
(
IUMLClass
,
lUMLClassAux
)
=
S_OK
then
begin
lUMLClassAux
:=
lModel
as
IUMLClass
;
lSession
:=
GetServiceSession
;
if
Assigned
(
lSession
)
then
begin
lCadastroClasseUC
:=
cxCadastroClasse
.
Create
(
lSession
);
try
lCadClasse
:=
TCadastroClasse
.
Create
(
nil
,
lCadastroClasseUC
,
lUMLClassAux
);
try
lCadClasse
:=
TCadastroClasse
.
Create
(
nil
,
lConnString
,
lUMLClassAux
);
if
lCadClasse
.
ShowModal
=
mrok
then
gStarUMLApp
.
SelectInModelExplorer
(
lCadClasse
.
UMLClass
);
finally
if
assigned
(
lCadClasse
)
then
lCadClasse
.
Free
;
lCadClasse
.
Free
;
end
;
finally
lCadastroClasseUC
.
Free
;
end
;
end
else
raise
Exception
.
Create
(
'This option is avaliable only for classes.'
);
end
;
end
else
raise
Exception
.
Create
(
'This option is avaliable only for classes.'
);
end
;
class
procedure
TDelphiAddInObj
.
ActionMenu_EditUseCase
;
var
lCadCasoDeUso
:
TCadastroCasoDeUso
;
lConnString
:
string
;
lSession
:
cxSession
;
lCadastroCasoUsoUC
:
cxCadatroCasoDeUso
;
lModel
:
IModel
;
lUMLUseCaseAux
:
IUMLUseCase
;
begin
lCadCasoDeUso
:=
nil
;
lConnString
:=
GetServiceConnectionString
;
if
lConnString
<>
''
then
begin
lModel
:=
gStarUMLApp
.
SelectionManager
.
GetSelectedModelAt
(
0
);
try
if
lModel
.
QueryInterface
(
IUMLUsecase
,
lUMLUseCaseAux
)
=
S_OK
then
begin
lUMLUseCaseAux
:=
lModel
as
IUMLUsecase
;
lCadCasoDeUso
:=
TCadastroCasoDeUso
.
Create
(
nil
,
lConnString
,
lUMLUseCaseAux
);
end
else
raise
exception
.
Create
(
'This option is only avaliable for Usecases.'
);
lSession
:=
GetServiceSession
;
if
assigned
(
lSession
)
then
begin
lCadastroCasoUsoUC
:=
cxCadatroCasoDeUso
.
Create
(
lSession
);
try
lCadCasoDeUso
:=
TCadastroCasoDeUso
.
Create
(
nil
,
lCadastroCasoUsoUC
,
lUMLUseCaseAux
);
try
if
lCadCasoDeUso
.
ShowModal
=
mrok
then
gStarUMLApp
.
SelectInModelExplorer
(
lCadCasoDeUso
.
UseCase
);
finally
if
assigned
(
lCadCasoDeUso
)
then
lCadCasoDeUso
.
Free
;
lCadCasoDeUso
.
Free
;
end
;
finally
lCadastroCasoUsoUC
.
Free
;
end
;
end
;
end
else
raise
exception
.
Create
(
'This option is only avaliable for Usecases.'
);
end
;
class
procedure
TDelphiAddInObj
.
ActionMenu_GeneratePreview
;
...
...
@@ -616,33 +624,34 @@ end;
class
procedure
TDelphiAddInObj
.
ActionMenu_InsertUseCase
;
var
lCadCasoDeUso
:
TCadastroCasoDeUso
;
l
ConnString
:
string
;
l
Session
:
cxSession
;
lCadastroCasoUsoUC
:
cxCadatroCasoDeUso
;
lModel
:
IModel
;
lUMLPackageAux
:
IUMLPackage
;
begin
lCadCasoDeUso
:=
nil
;
l
ConnString
:=
GetServiceConnectionString
;
if
lConnString
<>
''
then
l
Session
:=
GetServiceSession
;
if
assigned
(
lSession
)
then
begin
lModel
:=
gStarUMLApp
.
SelectionManager
.
GetSelectedModelAt
(
0
);
lCadastroCasoUsoUC
:=
cxCadatroCasoDeUso
.
Create
(
lSession
);
try
lCadCasoDeUso
:=
TCadastroCasoDeUso
.
Create
(
nil
,
lCadastroCasoUsoUC
,
Nil
);
try
if
lModel
.
QueryInterface
(
IUMLPackage
,
lUMLPackageAux
)
=
S_OK
then
begin
lCadCasoDeUso
:=
TCadastroCasoDeUso
.
Create
(
nil
,
lConnString
,
Nil
);
lCadCasoDeUso
.
UseCasePackage
:=
lModel
as
IUMLPackage
;
end
else
begin
lCadCasoDeUso
:=
TCadastroCasoDeUso
.
Create
(
nil
,
lConnString
,
Nil
);
end
;
if
lCadCasoDeUso
.
ShowModal
=
mrok
then
gStarUMLApp
.
SelectInModelExplorer
(
lCadCasoDeUso
.
UseCase
);
finally
if
assigned
(
lCadCasoDeUso
)
then
lCadCasoDeUso
.
Free
;
end
;
finally
lCadastroCasoUsoUC
.
Free
;
end
;
end
;
end
;
...
...
EvoUMLPlugin/src/InstantCode/InstantTextFiler.pas
View file @
d36b4459
...
...
@@ -30,11 +30,7 @@
unit
InstantTextFiler
;
{$IFDEF LINUX}
{$I '../InstantDefines.inc'}
{$ELSE}
{$I 'InstantDefines.inc'}
{$ENDIF}
interface
...
...
EvoUMLPlugin/src/IntegracaoDelphiSUML.pas
View file @
d36b4459
...
...
@@ -118,8 +118,6 @@ type
function
GerarBodyStateMachine_CSharp
(
piModelMappingsOptions
:
TModelMappingsOptions
;
piStateMachine
:
utStateMachine
;
piUseCaseTicketCode
:
string
;
piUnitRegisterMappings
:
PStringWriter
):
string
;
function
GerarBodyStateMachine_Java
(
piModelMappingsOptions
:
TModelMappingsOptions
;
piStateMachine
:
utStateMachine
;
piUseCaseTicketCode
:
string
;
piUnitRegisterMappings
:
PStringWriter
):
string
;
function
GerarUnitOQL
(
piXMLFileName
:
string
):
string
;
procedure
SaveUseCaseDiagramJPG
(
piUseCaseName
,
piTargetDirectory
:
string
);
procedure
SaveAllDiagrams
(
const
piTargetDirectory
:
string
);
...
...
@@ -168,34 +166,40 @@ type
property
StarUMLApp
:
IStarUMLApplication
read
fStarUMLApp
;
end
;
function
InitializeAddIn
(
AApplicationHandle
:
THandle
;
AStarUMLApplication
:
TObject
):
Integer
;
cdecl
;
function
FinalizeAddIn
:
Integer
;
cdecl
;
function
DoMenuAction
(
ActionID
:
Integer
):
Integer
;
cdecl
;
function
InitializeAddIn
(
AApplicationHandle
:
THandle
;
AStarUMLApplication
:
TObject
):
Integer
;
{$IFDEF MSWINDOWS}
stdcall
;
{$ELSE}
cdecl
;
{$ENDIF}
function
FinalizeAddIn
:
Integer
;
{$IFDEF MSWINDOWS}
stdcall
;
{$ELSE}
cdecl
;
{$ENDIF}
function
DoMenuAction
(
ActionID
:
Integer
):
Integer
;
{$IFDEF MSWINDOWS}
stdcall
;
{$ELSE}
cdecl
;
{$ENDIF}
var
gStarUMLApp
:
IStarUMLApplication
;
implementation
uses
dialogs
,
uDBAttributeParameters
,
acuUseCaseStateMachine
,
acuFramework
,
Forms
,
DelphiAddInObj
,
Controls
,
strutils
,
utuMessage
,
acuOQL
,
utuXSD
,
utuOQL
,
acuModelMapping
;
Controls
,
strutils
,
utuMessage
,
utuXSD
,
acuModelMapping
;
function
InitializeAddIn
(
AApplicationHandle
:
THandle
;
AStarUMLApplication
:
TObject
):
Integer
;
cdecl
;
function
InitializeAddIn
(
AApplicationHandle
:
THandle
;
AStarUMLApplication
:
TObject
):
Integer
;
{$IFDEF MSWINDOWS}
stdcall
;
{$ELSE}
cdecl
;
{$ENDIF}
begin
// Application.Handle := AApplicationHandle;
if
AStarUMLApplication
.
GetInterface
(
IID_IStarUMLApplication
,
gStarUMLApp
)
then
Result
:=
0
else
Result
:=
-
1
;
end
;
function
FinalizeAddIn
:
Integer
;
cdecl
;
function
FinalizeAddIn
:
Integer
;
{$IFDEF MSWINDOWS}
stdcall
;
{$ELSE}
cdecl
;
{$ENDIF}
begin
Result
:=
0
;
gStarUMLApp
:=
Nil
;
end
;
function
DoMenuAction
(
ActionID
:
Integer
):
Integer
;
cdecl
;
function
DoMenuAction
(
ActionID
:
Integer
):
Integer
;
{$IFDEF MSWINDOWS}
stdcall
;
{$ELSE}
cdecl
;
{$ENDIF}
begin
try
Result
:=
TDelphiAddInObj
.
DoMenuAction
(
ActionID
);
except
on
E
:
Exception
do
begin
Application
.
MessageBox
(
PAnsiChar
(
e
.
Message
),
'Error...'
,
MB_ICONERROR
);
end
;
end
;
end
;
...
...
@@ -1542,18 +1546,20 @@ begin
try
// Obtm Gerenciador de Projeto do STARUML
lPrjManager
:=
gStarUMLApp
.
Get_ProjectManager
;
// lPrjManager.OpenProject(pFileName);
// Obtm projeto do STARUML de onde sero extrados os elementos UML
lPrj
:=
lPrjManager
.
Get_Project
;
if
assigned
(
lPrj
)
then
begin
// Meta Modelo do Star UML
lIMetaModel
:=
gStarUMLApp
.
MetaModel
;
//Obtem a classe acPersistentObject do modelo do StarUML
lElement
:=
gStarUMLApp
.
FindByPathname
(
MODELO
+
'::FrameworkModel::acuFrameworkPackage::'
+
cBASE_PERSISTENT_OBJECT_CLASS
);
if
not
assigned
(
lElement
)
then
raise
Exception
.
Create
(
format
(
'Base class "%s" not found. Try to reopen model.'
,
[
cBASE_PERSISTENT_OBJECT_CLASS
]));
if
assigned
(
lElement
)
then
begin
lClassePersistentObject
:=
lElement
as
IUMLClass
;
lLostClasses
:=
TStringList
.
Create
;
...
...
@@ -1566,22 +1572,14 @@ begin
lLostClasses
.
Free
;
end
;
// if (lacMetaModel.ClassTickets.Count = 0) then
result
:=
AlimentarMetamodelRegisterMapping
(
lClassePersistentObject
,
MetaModel
,
piMetaModelOptions
,
piProgress
);
// Busca metaclasse UMLMODEL no metamodelo
// lMetaClass := lIMetaModel.FindMetaClass('UMLModel');
// Obtem modelo especfico para geraao de cdigo fonte
// lModel := pStarUMLApp.SelectionManager.GetSelectedModelAt(0) as IUMLModel;
lElement
:=
gStarUMLApp
.
FindByPathname
(
MODELO
);
lModel
:=
lElement
as
IUMLModel
;
lPackage
:=
lModel
as
IUMLPackage
;
// if (lacMetaModel.RelationTickets.Count = 0) then
result
:=
AlimentarMetamodelRelationsAll
(
lPackage
,
MetaModel
,
piMetaModelOptions
,
piProgress
);
// lElement := pStarUMLApp.FindByPathname(MODELO + '::FrameworkModel::ApplicationFramework::ucSecuredUseCase');
lElement
:=
gStarUMLApp
.
FindByPathname
(
MODELO
+
'::FrameworkModel::acuFrameworkPackage::UCU::ucUseCase'
);
if
not
assigned
(
lElement
)
then
raise
Exception
.
Create
(
'Use case "ucUseCase" not found.'
);
...
...
@@ -1607,11 +1605,11 @@ begin
lUMLBaseSubmachineState
.
Submachine
:=
nil
;
lElement
:=
nil
;
if
not
piMetaModelOptions
.
SilentMode
then
PutMessage
(
FormatDateTime
(
'hh:nn:ss'
,
Time
)
+
' - Model mappings generated.'
,
gStarUMLApp
.
GetProject
,
2
);
// MetaModel.SetOrder;
end
;
end
;
finally
end
;
end
;
function
TUtil
.
AlimentarMetamodelRegisterMapping
(
poClasseRaiz
:
IUMLClass
;
poMetaModel
:
acMetaModel
;
piMetaModelOptions
:
TMetaModelGenerationOptions
;
piProgress
:
TFShowProgress
):
string
;
...
...
@@ -2667,242 +2665,6 @@ begin
piUnitRegisterMappings
.
Outdent
();
end
;
function
TUtil
.
GerarUnitOQL
(
piXMLFileName
:
String
):
string
;
procedure
AddText
(
piStringStream
:
TStringStream
;
piIndent
:
integer
=
0
;
piText
:
string
=
''
);
begin
piText
:=
StringOfChar
(
' '
,
piIndent
)
+
piText
;
piStringStream
.
WriteString
(
concat
(
piText
,#
13
#
10
));
end
;
var
lUnit
:
TStringStream
;
lFieldOQLFile
,
lFieldOQL
:
utField
;
lAux
:
TStringList
;
lOQLName
,
lOQLQuery
:
string
;
lEnum
,
lEnumParams
:
acEnumerator
;
lOQLParam
:
acOQLParam
;
// lQuery: acAbstractOQLQuery;
lFileName
:
string
;
lOQLType
:
integer
;
begin
if
not
FileExists
(
piXMLFileName
)
then
raise
Exception
.
Create
(
'File "'
+
piXMLFileName
+
'" does not exist'
);
lUnit
:=
TStringStream
.
Create
(
''
);
try
lFieldOQLFile
:=
utField
.
Create
;
try
lAux
:=
TStringList
.
Create
;
try
lAux
.
LoadFromFile
(
piXMLFileName
);
lFieldOQLFile
.
LoadFieldFromXMLString
(
lAux
.
Text
);
finally
lAux
.
free
;
end
;
lFileName
:=
ExtractFileName
(
piXMLFileName
);
lFileName
:=
LeftStr
(
lFileName
,
pos
(
'.'
,
lFileName
)
-
1
);
AddText
(
lUnit
,
0
,
'unit utu'
+
lFileName
+
';'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'interface'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'uses acuOQL, acuFramework;'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'type'
);
AddText
(
lUnit
);
lEnum
:=
lFieldOQLFile
.
GetFieldsEnumerator
;
try
//OQL Interfaces
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
if
not
lFieldOQL
.
HasAttribute
(
'name'
)
then
raise
Exception
.
Create
(
'Attribute "name" not found for OQL. Not a valid XML OQL file.'
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
if
not
lFieldOQL
.
HasField
(
'query'
)
then
raise
Exception
.
Create
(
'Field "query" not found for OQL. Not a valid XML OQL file.'
);
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
//Default cOQLQuery
lOQLType
:=
cOQLQuery
;
if
lFieldOQL
.
HasAttribute
(
'oqltype'
)
then
lOQLType
:=
lFieldOQL
.
AttributeByName
(
'oqltype'
).
AsInteger
;
case
lOQLType
of
cDataSetOQLDataSet
:
AddText
(
lUnit
,
2
,
'I'
+
lOQLName
+
' = interface(IDataSetOQLQuery)'
);
else
AddText
(
lUnit
,
2
,
'I'
+
lOQLName
+
' = interface(IOQLQuery)'
);
end
;
// case lOQLType of
// cDataSetOQLDataSet: lQuery := acDataSetOQLQuery.Create(piSession, lOQLQuery);
// else lQuery := acOQLQuery.Create(piSession, lOQLQuery);
// end;
// try
// lEnumParams := lQuery.Parameters.GetEnumerator;
// try
// while not lEnumParams.EOL do
// begin
// lOQLParam := acOQLParam(lEnumParams.Current);
// AddText(lUnit, 4, 'function Param_' + lOQLParam.Name + ': ' + lOQLParam.ClassName + ';');
// lEnumParams.MoveNext;
// end;
// finally
// lEnumParams.free;
// end;
// AddText(lUnit, 2, 'end;');
// AddText(lUnit);
// finally
// lQuery.Free;
// end;
// lEnum.MoveNext;
end
;
//Factory Class Interface
AddText
(
lUnit
,
2
,
'ut'
+
lFileName
+
' = class'
);
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
AddText
(
lUnit
,
4
,
'class function '
+
lOQLName
+
'(piSessao: acPersistenceSession): '
+
'I'
+
lOQLName
+
';'
);
lEnum
.
MoveNext
;
end
;
AddText
(
lUnit
,
2
,
'end;'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'implementation'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'type'
);
AddText
(
lUnit
);
//OQL Types
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
//Default cOQLQuery
lOQLType
:=
cOQLQuery
;
if
lFieldOQL
.
HasAttribute
(
'oqltype'
)
then
lOQLType
:=
lFieldOQL
.
AttributeByName
(
'oqltype'
).
AsInteger
;
case
lOQLType
of
cDataSetOQLDataSet
:
AddText
(
lUnit
,
2
,
'T'
+
lOQLName
+
' = class(acDataSetOQLQuery, '
+
'I'
+
lOQLName
+
')'
);
else
AddText
(
lUnit
,
2
,
'T'
+
lOQLName
+
' = class(acOQLQuery, '
+
'I'
+
lOQLName
+
')'
);
end
;
// case lOQLType of
// cDataSetOQLDataSet: lQuery := acDataSetOQLQuery.Create(piSession, lOQLQuery);
// else lQuery := acOQLQuery.Create(piSession, lOQLQuery);
// end;
// try
// lEnumParams := lQuery.Parameters.GetEnumerator;
// try
// while not lEnumParams.EOL do
// begin
// lOQLParam := acOQLParam(lEnumParams.Current);
// AddText(lUnit, 4, 'function Param_' + lOQLParam.Name + ': ' + lOQLParam.ClassName + ';');
// lEnumParams.MoveNext;
// end;
// finally
// lEnumParams.free;
// end;
// AddText(lUnit, 2, 'end;');
// AddText(lUnit);
// finally
// lQuery.Free;
// end;
lEnum
.
MoveNext
;
end
;
//OQL Types Implementation
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
//Default cOQLQuery
lOQLType
:=
cOQLQuery
;
if
lFieldOQL
.
HasAttribute
(
'oqltype'
)
then
lOQLType
:=
lFieldOQL
.
AttributeByName
(
'oqltype'
).
AsInteger
;
AddText
(
lUnit
,
0
,
'{ T'
+
lOQLName
+
' }'
);
AddText
(
lUnit
);
// case lOQLType of
// cDataSetOQLDataSet: lQuery := acDataSetOQLQuery.Create(piSession, lOQLQuery);
// else lQuery := acOQLQuery.Create(piSession, lOQLQuery);
// end;
// try
// lEnumParams := lQuery.Parameters.GetEnumerator;
// try
// while not lEnumParams.EOL do
// begin
// lOQLParam := acOQLParam(lEnumParams.Current);
// AddText(lUnit, 0, 'function T' + lOQLName + '.Param_' + lOQLParam.Name + ': ' + lOQLParam.ClassName + ';');
// AddText(lUnit, 0,'begin');
// AddText(lUnit, 2,'result := ' + lOQLParam.ClassName + '(Self.ParamByName(' + QuotedStr(lOQLParam.Name) + '));');
// AddText(lUnit, 0,'end;');
// AddText(lUnit);
// lEnumParams.MoveNext;
// end;
// finally
// lEnumParams.free;
// end;
// finally
// lQuery.Free;
// end;
lEnum
.
MoveNext
;
end
;
//Factory Class Implementation
AddText
(
lUnit
,
0
,
'{ utOQLs }'
);
AddText
(
lUnit
);
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
AddText
(
lUnit
,
0
,
'class function ut'
+
lFileName
+
'.'
+
lOQLName
+
'(piSessao: acPersistenceSession): I'
+
lOQLName
+
';'
);
AddText
(
lUnit
,
0
,
'begin'
);
AddText
(
lUnit
,
2
,
'result := T'
+
lOQLName
+
'.Create(pisessao,'
);
lOQLQuery
:=
StringReplace
(
lOQLQuery
,
''''
,
''''''
,
[
rfReplaceAll
]);
lOQLQuery
:=
StringReplace
(
lOQLQuery
,
#
13
#
10
,
''' + #13#10 +'
+
#
13
#
10
+
''''
,
[
rfReplaceAll
]);
AddText
(
lUnit
,
0
,
''''
+
lOQLQuery
+
''');'
);
AddText
(
lUnit
,
0
,
'end;'
);
AddText
(
lUnit
);
lEnum
.
MoveNext
;
end
;
finally
lEnum
.
free
;
end
;
AddText
(
lUnit
,
0
,
'end.'
);
result
:=
lUnit
.
DataString
;
finally
lFieldOQLFile
.
free
;
end
;
finally
lUnit
.
free
;
end
;
end
;
procedure
TUtil
.
GerarUnitRegisterModelMappings
(
piModelMappingsOptions
:
TModelMappingsOptions
;
piProgress
:
TFShowProgress
);
const
MAX_UC
=
100
;
...
...
@@ -5316,7 +5078,7 @@ begin
GerarRelationsPartnerShips
(
lClassTicket
,
lInstantCodeClass
);
lInstantCodeModule
.
ImplementationSection
.
Clear
;
lInstantCodeModule
.
InitializationSection
.
CodeText
:=
'
PersistenceManager.RegisterClass('
+
lsNomeClasse
+
'
);'
;
lInstantCodeModule
.
InitializationSection
.
CodeText
:=
'
// PersistenceManager.RegisterClass(TypeOf('
+
lsNomeClasse
+
')
);'
;
result
:=
lInstantCodeModule
.
AsString
;
// end
...
...
EvoUMLPlugin/src/fCodeGen.dfm
View file @
d36b4459
...
...
@@ -10,8 +10,10 @@ object CodeGen: TCodeGen
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
KeyPreview = True
OnShow = FormShow
Position = poDesktopCenter
LCLVersion = '2.0.0.4'
object PageControl1: TPageControl
Left = 0
Height = 616
...
...
@@ -23,26 +25,26 @@ object CodeGen: TCodeGen
TabOrder = 0
object TabSheet1: TTabSheet
Caption = 'UseCase'
ClientHeight = 5
77
ClientWidth = 8
83
ClientHeight = 5
88
ClientWidth = 8
79
object Panel3: TPanel
Left = 0
Height = 5
77
Height = 5
88
Top = 0
Width = 8
83
Width = 8
79
Align = alClient
BevelOuter = bvLowered
ClientHeight = 5
77
ClientWidth = 8
83
ClientHeight = 5
88
ClientWidth = 8
79
TabOrder = 0
object Panel2: TPanel
Left = 1
Height = 4
52
Height = 4
63
Top = 124
Width = 280
Align = alLeft
BevelOuter = bvNone
ClientHeight = 4
52
ClientHeight = 4
63
ClientWidth = 280
TabOrder = 0
object Panel4: TPanel
...
...
@@ -197,7 +199,7 @@ object CodeGen: TCodeGen
end
object lvUseCases: TListView
Left = 0
Height = 3
67
Height = 3
78
Top = 41
Width = 280
Align = alClient
...
...
@@ -205,7 +207,7 @@ object CodeGen: TCodeGen
Columns = <
item
Caption = 'UseCase'
Width = 25
0
Width = 25
8
end>
MultiSelect = True
ReadOnly = True
...
...
@@ -218,7 +220,7 @@ object CodeGen: TCodeGen
object Panel13: TPanel
Left = 0
Height = 44
Top = 4
08
Top = 4
19
Width = 280
Align = alBottom
BevelInner = bvLowered
...
...
@@ -241,33 +243,33 @@ object CodeGen: TCodeGen
end
object PageControl2: TPageControl
Left = 281
Height = 4
52
Height = 4
63
Top = 124
Width =
601
Width =
597
ActivePage = TabSheet2
Align = alClient
TabIndex = 0
TabOrder = 1
object TabSheet2: TTabSheet
Caption = 'Usecase'
ClientHeight = 4
13
ClientWidth = 5
95
ClientHeight = 4
35
ClientWidth = 5
87
object Panel5: TPanel
Left = 0
Height = 4
13
Height = 4
35
Top = 0
Width = 5
95
Width = 5
87
Align = alClient
BevelInner = bvLowered
Caption = 'Panel5'
ClientHeight = 4
13
ClientWidth = 5
95
ClientHeight = 4
35
ClientWidth = 5
87
TabOrder = 0
object Panel6: TPanel
Left = 2
Height = 20
Top = 2
Width = 5
91
Width = 5
83
Align = alTop
BevelInner = bvLowered
Caption = 'UseCase code preview'
...
...
@@ -275,9 +277,9 @@ object CodeGen: TCodeGen
end
inline memCode: TSynEdit
Left = 2
Height =
389
Height =
411
Top = 22
Width = 5
91
Width = 5
83
Align = alClient
Font.Color = clWindowText
Font.Height = -13
...
...
@@ -355,8 +357,8 @@ object CodeGen: TCodeGen
end
object TabSheet3: TTabSheet
Caption = 'XSD'
ClientHeight = 4
13
ClientWidth = 5
95
ClientHeight = 4
35
ClientWidth = 5
87
ImageIndex = 1
object lvXSD: TListView
Left = 0
...
...
@@ -404,8 +406,8 @@ object CodeGen: TCodeGen
TabOrder = 1
object TabSheet4: TTabSheet
Caption = 'XSD In'
ClientHeight = 2
45
ClientWidth = 5
89
ClientHeight = 2
80
ClientWidth = 5
91
inline memXSDIn: TSynEdit
Left = 0
Height = 245
...
...
@@ -487,8 +489,8 @@ object CodeGen: TCodeGen
end
object TabSheet5: TTabSheet
Caption = 'XSD Out'
ClientHeight = 2
45
ClientWidth = 5
89
ClientHeight = 2
80
ClientWidth = 5
91
ImageIndex = 1
inline memXSDOut: TSynEdit
Left = 0
...
...
@@ -576,27 +578,27 @@ object CodeGen: TCodeGen
Left = 1
Height = 123
Top = 1
Width = 8
81
Width = 8
77
ActivePage = TabSheet7
Align = alTop
TabIndex = 0
TabOrder = 2
object TabSheet7: TTabSheet
Caption = 'General'
ClientHeight =
84
ClientWidth = 8
75
ClientHeight =
95
ClientWidth = 8
67
object Panel1: TPanel
Left = 0
Height =
84
Height =
95
Top = 0
Width = 8
75
Width = 8
67
Align = alClient
Caption = 'General'
ClientHeight =
84
ClientWidth = 8
75
ClientHeight =
95
ClientWidth = 8
67
TabOrder = 0
object SpeedButton6: TSpeedButton
Left = 76
8
Left = 76
1
Height = 71
Top = 15
Width = 100
...
...
@@ -837,8 +839,8 @@ object CodeGen: TCodeGen
ChildSizing.ShrinkVertical = crsScaleChilds
ChildSizing.Layout = cclLeftToRightThenTopToBottom
ChildSizing.ControlsPerLine = 1
ClientHeight = 6
7
ClientWidth =
87
ClientHeight = 6
9
ClientWidth =
93
ItemIndex = 0
Items.Strings = (
'Server'
...
...
@@ -861,8 +863,8 @@ object CodeGen: TCodeGen
ChildSizing.ShrinkVertical = crsScaleChilds
ChildSizing.Layout = cclLeftToRightThenTopToBottom
ChildSizing.ControlsPerLine = 1
ClientHeight = 6
7
ClientWidth = 9
0
ClientHeight = 6
9
ClientWidth = 9
6
ItemIndex = 0
Items.Strings = (
'Delphi'
...
...
@@ -878,8 +880,8 @@ object CodeGen: TCodeGen
Top = 7
Width = 537
Caption = 'Output directory'
ClientHeight = 6
7
ClientWidth = 5
29
ClientHeight = 6
9
ClientWidth = 5
35
TabOrder = 2
object SpeedButton5: TSpeedButton
Left = 503
...
...
@@ -919,7 +921,7 @@ object CodeGen: TCodeGen
end
object edtDirectory: TEdit
Left = 10
Height =
22
Height =
31
Top = 33
Width = 487
TabOrder = 0
...
...
@@ -929,8 +931,8 @@ object CodeGen: TCodeGen
end
object Options: TTabSheet
Caption = 'Options'
ClientHeight = 9
7
ClientWidth = 8
71
ClientHeight = 9
5
ClientWidth = 8
67
ImageIndex = 1
object Panel9: TPanel
Left = 380
...
...
@@ -953,8 +955,8 @@ object CodeGen: TCodeGen
TabOrder = 0
object TabSheet8: TTabSheet
Caption = 'Java'
ClientHeight =
54
ClientWidth = 48
1
ClientHeight =
89
ClientWidth = 48
3
object Label1: TLabel
Left = 10
Height = 13
...
...
@@ -1012,8 +1014,8 @@ object CodeGen: TCodeGen
end
object TabSheet6: TTabSheet
Caption = 'SQL'
ClientHeight = 5
90
ClientWidth = 8
81
ClientHeight = 5
88
ClientWidth = 8
79
ImageIndex = 1
object PageControl5: TPageControl
Left = 0
...
...
@@ -1026,8 +1028,8 @@ object CodeGen: TCodeGen
TabOrder = 0
object TabSheet9: TTabSheet
Caption = 'SQL Server'
ClientHeight = 5
51
ClientWidth = 87
5
ClientHeight = 5
86
ClientWidth = 87
7
object Panel7: TPanel
Left = 0
Height = 564
...
...
@@ -1035,8 +1037,8 @@ object CodeGen: TCodeGen
Width = 873
Align = alClient
BevelOuter = bvLowered
ClientHeight = 56
4
ClientWidth = 8
73
ClientHeight = 56
0
ClientWidth = 8
69
TabOrder = 0
object Panel8: TPanel
Left = 1
...
...
@@ -1044,8 +1046,8 @@ object CodeGen: TCodeGen
Top = 1
Width = 871
Align = alTop
ClientHeight =
40
ClientWidth = 8
71
ClientHeight =
36
ClientWidth = 8
67
TabOrder = 0
object SpeedButton4: TSpeedButton
Left = 9
...
...
@@ -1138,8 +1140,8 @@ object CodeGen: TCodeGen
end
object TabSheet10: TTabSheet
Caption = 'Oracle'
ClientHeight = 5
64
ClientWidth = 87
3
ClientHeight = 5
86
ClientWidth = 87
7
ImageIndex = 1
object Panel11: TPanel
Left = 0
...
...
@@ -1148,8 +1150,8 @@ object CodeGen: TCodeGen
Width = 873
Align = alClient
BevelOuter = bvLowered
ClientHeight = 56
4
ClientWidth = 8
73
ClientHeight = 56
0
ClientWidth = 8
69
TabOrder = 0
object Panel12: TPanel
Left = 1
...
...
@@ -1157,8 +1159,8 @@ object CodeGen: TCodeGen
Top = 1
Width = 871
Align = alTop
ClientHeight =
40
ClientWidth = 8
71
ClientHeight =
36
ClientWidth = 8
67
TabOrder = 0
object SpeedButton7: TSpeedButton
Left = 9
...
...
@@ -1251,8 +1253,8 @@ object CodeGen: TCodeGen
end
object TabSheet11: TTabSheet
Caption = 'DB2'
ClientHeight = 5
64
ClientWidth = 87
3
ClientHeight = 5
86
ClientWidth = 87
7
ImageIndex = 2
object Panel14: TPanel
Left = 0
...
...
@@ -1261,8 +1263,8 @@ object CodeGen: TCodeGen
Width = 873
Align = alClient
BevelOuter = bvLowered
ClientHeight = 56
4
ClientWidth = 8
73
ClientHeight = 56
0
ClientWidth = 8
69
TabOrder = 0
object Panel15: TPanel
Left = 1
...
...
@@ -1270,8 +1272,8 @@ object CodeGen: TCodeGen
Top = 1
Width = 871
Align = alTop
ClientHeight =
40
ClientWidth = 8
71
ClientHeight =
36
ClientWidth = 8
67
TabOrder = 0
object SpeedButton8: TSpeedButton
Left = 9
...
...
EvoUMLPlugin/src/formMemo.dfm
View file @
d36b4459
object PreviewClassCode: TPreviewClassCode
Left =
0
Height = 5
73
Top =
0
Width =
799
Left =
2149
Height = 5
80
Top =
247
Width =
803
Caption = 'Preview Class Code'
ClientHeight = 5
73
ClientWidth =
799
ClientHeight = 5
80
ClientWidth =
803
Color = clBtnFace
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
KeyPreview = True
Position = poScreenCenter
LCLVersion = '2.0.0.4'
object Panel2: TPanel
Left = 0
Height = 5
73
Height = 5
80
Top = 0
Width =
799
Width =
803
Align = alClient
BevelOuter = bvLowered
ClientHeight = 5
73
ClientWidth =
799
ClientHeight = 5
80
ClientWidth =
803
TabOrder = 0
object Panel1: TPanel
Left = 1
Height = 40
Top = 1
Width =
797
Width =
801
Align = alTop
ClientHeight = 40
ClientWidth =
797
ClientWidth =
801
TabOrder = 0
object Button1: TButton
Left = 12
...
...
@@ -42,9 +44,9 @@ object PreviewClassCode: TPreviewClassCode
end
object pgc_Main: TPageControl
Left = 1
Height = 53
1
Height = 53
8
Top = 41
Width =
797
Width =
801
ActivePage = TabSheet1
Align = alClient
ShowTabs = False
...
...
@@ -52,45 +54,476 @@ object PreviewClassCode: TPreviewClassCode
TabOrder = 1
object TabSheet1: TTabSheet
Caption = 'Class Preview'
ClientHeight = 5
2
4
ClientWidth = 7
89
ClientHeight = 5
3
4
ClientWidth = 7
91
object pgc_ClassCode: TPageControl
Left = 0
Height = 5
2
4
Height = 5
3
4
Top = 0
Width = 7
89
Width = 7
91
ActivePage = TabSheet3
Align = alClient
TabIndex = 0
TabOrder = 0
object TabSheet3: TTabSheet
Caption = '
Delphi
'
ClientHeight =
485
ClientWidth = 78
3
Caption = '
ObjPascal
'
ClientHeight =
506
ClientWidth = 78
1
inline mem_ClassPascal: TSynEdit
Left = 0
Height =
485
Height =
506
Top = 0
Width = 78
3
Width = 78
1
Align = alClient
Color = clWindow
Font.Color = clWindowText
Font.Height =
-
13
Font.Name = '
Courier New
'
Font.Height = 13
Font.Name = '
DejaVu Sans Mono
'
Font.Pitch = fpFixed
Font.Quality = fqNonAntialiased
ParentColor = False
ParentFont = False
TabOrder = 0
Gutter.Width = 57
BorderStyle = bsNone
Gutter.Width = 23
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
Keystrokes = <>
Highlighter = SynFreePascalSyn1
Keystrokes = <
item
Command = ecUp
ShortCut = 38
end
item
Command = ecSelUp
ShortCut = 8230
end
item
Command = ecScrollUp
ShortCut = 16422
end
item
Command = ecDown
ShortCut = 40
end
item
Command = ecSelDown
ShortCut = 8232
end
item
Command = ecScrollDown
ShortCut = 16424
end
item
Command = ecLeft
ShortCut = 37
end
item
Command = ecSelLeft
ShortCut = 8229
end
item
Command = ecWordLeft
ShortCut = 16421
end
item
Command = ecSelWordLeft
ShortCut = 24613
end
item
Command = ecRight
ShortCut = 39
end
item
Command = ecSelRight
ShortCut = 8231
end
item
Command = ecWordRight
ShortCut = 16423
end
item
Command = ecSelWordRight
ShortCut = 24615
end
item
Command = ecPageDown
ShortCut = 34
end
item
Command = ecSelPageDown
ShortCut = 8226
end
item
Command = ecPageBottom
ShortCut = 16418
end
item
Command = ecSelPageBottom
ShortCut = 24610
end
item
Command = ecPageUp
ShortCut = 33
end
item
Command = ecSelPageUp
ShortCut = 8225
end
item
Command = ecPageTop
ShortCut = 16417
end
item
Command = ecSelPageTop
ShortCut = 24609
end
item
Command = ecLineStart
ShortCut = 36
end
item
Command = ecSelLineStart
ShortCut = 8228
end
item
Command = ecEditorTop
ShortCut = 16420
end
item
Command = ecSelEditorTop
ShortCut = 24612
end
item
Command = ecLineEnd
ShortCut = 35
end
item
Command = ecSelLineEnd
ShortCut = 8227
end
item
Command = ecEditorBottom
ShortCut = 16419
end
item
Command = ecSelEditorBottom
ShortCut = 24611
end
item
Command = ecToggleMode
ShortCut = 45
end
item
Command = ecCopy
ShortCut = 16429
end
item
Command = ecPaste
ShortCut = 8237
end
item
Command = ecDeleteChar
ShortCut = 46
end
item
Command = ecCut
ShortCut = 8238
end
item
Command = ecDeleteLastChar
ShortCut = 8
end
item
Command = ecDeleteLastChar
ShortCut = 8200
end
item
Command = ecDeleteLastWord
ShortCut = 16392
end
item
Command = ecUndo
ShortCut = 32776
end
item
Command = ecRedo
ShortCut = 40968
end
item
Command = ecLineBreak
ShortCut = 13
end
item
Command = ecSelectAll
ShortCut = 16449
end
item
Command = ecCopy
ShortCut = 16451
end
item
Command = ecBlockIndent
ShortCut = 24649
end
item
Command = ecLineBreak
ShortCut = 16461
end
item
Command = ecInsertLine
ShortCut = 16462
end
item
Command = ecDeleteWord
ShortCut = 16468
end
item
Command = ecBlockUnindent
ShortCut = 24661
end
item
Command = ecPaste
ShortCut = 16470
end
item
Command = ecCut
ShortCut = 16472
end
item
Command = ecDeleteLine
ShortCut = 16473
end
item
Command = ecDeleteEOL
ShortCut = 24665
end
item
Command = ecUndo
ShortCut = 16474
end
item
Command = ecRedo
ShortCut = 24666
end
item
Command = ecGotoMarker0
ShortCut = 16432
end
item
Command = ecGotoMarker1
ShortCut = 16433
end
item
Command = ecGotoMarker2
ShortCut = 16434
end
item
Command = ecGotoMarker3
ShortCut = 16435
end
item
Command = ecGotoMarker4
ShortCut = 16436
end
item
Command = ecGotoMarker5
ShortCut = 16437
end
item
Command = ecGotoMarker6
ShortCut = 16438
end
item
Command = ecGotoMarker7
ShortCut = 16439
end
item
Command = ecGotoMarker8
ShortCut = 16440
end
item
Command = ecGotoMarker9
ShortCut = 16441
end
item
Command = ecSetMarker0
ShortCut = 24624
end
item
Command = ecSetMarker1
ShortCut = 24625
end
item
Command = ecSetMarker2
ShortCut = 24626
end
item
Command = ecSetMarker3
ShortCut = 24627
end
item
Command = ecSetMarker4
ShortCut = 24628
end
item
Command = ecSetMarker5
ShortCut = 24629
end
item
Command = ecSetMarker6
ShortCut = 24630
end
item
Command = ecSetMarker7
ShortCut = 24631
end
item
Command = ecSetMarker8
ShortCut = 24632
end
item
Command = ecSetMarker9
ShortCut = 24633
end
item
Command = EcFoldLevel1
ShortCut = 41009
end
item
Command = EcFoldLevel2
ShortCut = 41010
end
item
Command = EcFoldLevel3
ShortCut = 41011
end
item
Command = EcFoldLevel4
ShortCut = 41012
end
item
Command = EcFoldLevel5
ShortCut = 41013
end
item
Command = EcFoldLevel6
ShortCut = 41014
end
item
Command = EcFoldLevel7
ShortCut = 41015
end
item
Command = EcFoldLevel8
ShortCut = 41016
end
item
Command = EcFoldLevel9
ShortCut = 41017
end
item
Command = EcFoldLevel0
ShortCut = 41008
end
item
Command = EcFoldCurrent
ShortCut = 41005
end
item
Command = EcUnFoldCurrent
ShortCut = 41003
end
item
Command = EcToggleMarkupWord
ShortCut = 32845
end
item
Command = ecNormalSelect
ShortCut = 24654
end
item
Command = ecColumnSelect
ShortCut = 24643
end
item
Command = ecLineSelect
ShortCut = 24652
end
item
Command = ecTab
ShortCut = 9
end
item
Command = ecShiftTab
ShortCut = 8201
end
item
Command = ecMatchBracket
ShortCut = 24642
end
item
Command = ecColSelUp
ShortCut = 40998
end
item
Command = ecColSelDown
ShortCut = 41000
end
item
Command = ecColSelLeft
ShortCut = 40997
end
item
Command = ecColSelRight
ShortCut = 40999
end
item
Command = ecColSelPageDown
ShortCut = 40994
end
item
Command = ecColSelPageBottom
ShortCut = 57378
end
item
Command = ecColSelPageUp
ShortCut = 40993
end
item
Command = ecColSelPageTop
ShortCut = 57377
end
item
Command = ecColSelLineStart
ShortCut = 40996
end
item
Command = ecColSelLineEnd
ShortCut = 40995
end
item
Command = ecColSelEditorTop
ShortCut = 57380
end
item
Command = ecColSelEditorBottom
ShortCut = 57379
end>
MouseActions = <>
MouseTextActions = <>
MouseSelActions = <>
Lines.Strings = (
''
)
Options = [eoAutoIndent, eoBracketHighlight, eoEnhanceHomeKey, eoGroupUndo, eoHalfPageScroll, eoHideRightMargin, eoSmartTabs, eoTabsToSpaces, eoTrimTrailingSpaces, eoAltSetsColumnMode]
Options2 = [eoEnhanceEndKey, eoFoldedCopyPaste, eoOverwriteBlock, eoColorSelectionTillEol]
MouseOptions = [emAltSetsColumnMode, emCtrlWheelZoom]
VisibleSpecialChars = [vscSpace, vscTabAtLast]
ReadOnly = True
RightEdge = 0
ScrollBars = ssAutoBoth
SelectedColor.BackPriority = 50
SelectedColor.ForePriority = 50
SelectedColor.FramePriority = 50
...
...
@@ -112,6 +545,7 @@ object PreviewClassCode: TPreviewClassCode
inline SynLeftGutterPartList1: TSynGutterPartList
object SynGutterMarks1: TSynGutterMarks
Width = 24
Visible = False
MouseActions = <>
end
object SynGutterLineNumber1: TSynGutterLineNumber
...
...
@@ -137,6 +571,7 @@ object PreviewClassCode: TPreviewClassCode
MarkupInfo.Foreground = clGray
end
object SynGutterCodeFolding1: TSynGutterCodeFolding
Visible = False
MouseActions = <>
MarkupInfo.Background = clNone
MarkupInfo.Foreground = clGray
...
...
@@ -148,15 +583,16 @@ object PreviewClassCode: TPreviewClassCode
end
object TabSheet4: TTabSheet
Caption = 'Java'
ClientHeight =
453
ClientWidth = 78
5
ClientHeight =
506
ClientWidth = 78
1
ImageIndex = 1
inline mem_ClassJava: TSynEdit
Left = 0
Height =
453
Height =
506
Top = 0
Width = 78
5
Width = 78
1
Align = alClient
Color = clWindow
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Courier New'
...
...
@@ -165,16 +601,446 @@ object PreviewClassCode: TPreviewClassCode
ParentColor = False
ParentFont = False
TabOrder = 0
Gutter.Width = 57
BorderStyle = bsNone
Gutter.Width = 23
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
Keystrokes = <>
Highlighter = SynJavaSyn1
Keystrokes = <
item
Command = ecUp
ShortCut = 38
end
item
Command = ecSelUp
ShortCut = 8230
end
item
Command = ecScrollUp
ShortCut = 16422
end
item
Command = ecDown
ShortCut = 40
end
item
Command = ecSelDown
ShortCut = 8232
end
item
Command = ecScrollDown
ShortCut = 16424
end
item
Command = ecLeft
ShortCut = 37
end
item
Command = ecSelLeft
ShortCut = 8229
end
item
Command = ecWordLeft
ShortCut = 16421
end
item
Command = ecSelWordLeft
ShortCut = 24613
end
item
Command = ecRight
ShortCut = 39
end
item
Command = ecSelRight
ShortCut = 8231
end
item
Command = ecWordRight
ShortCut = 16423
end
item
Command = ecSelWordRight
ShortCut = 24615
end
item
Command = ecPageDown
ShortCut = 34
end
item
Command = ecSelPageDown
ShortCut = 8226
end
item
Command = ecPageBottom
ShortCut = 16418
end
item
Command = ecSelPageBottom
ShortCut = 24610
end
item
Command = ecPageUp
ShortCut = 33
end
item
Command = ecSelPageUp
ShortCut = 8225
end
item
Command = ecPageTop
ShortCut = 16417
end
item
Command = ecSelPageTop
ShortCut = 24609
end
item
Command = ecLineStart
ShortCut = 36
end
item
Command = ecSelLineStart
ShortCut = 8228
end
item
Command = ecEditorTop
ShortCut = 16420
end
item
Command = ecSelEditorTop
ShortCut = 24612
end
item
Command = ecLineEnd
ShortCut = 35
end
item
Command = ecSelLineEnd
ShortCut = 8227
end
item
Command = ecEditorBottom
ShortCut = 16419
end
item
Command = ecSelEditorBottom
ShortCut = 24611
end
item
Command = ecToggleMode
ShortCut = 45
end
item
Command = ecCopy
ShortCut = 16429
end
item
Command = ecPaste
ShortCut = 8237
end
item
Command = ecDeleteChar
ShortCut = 46
end
item
Command = ecCut
ShortCut = 8238
end
item
Command = ecDeleteLastChar
ShortCut = 8
end
item
Command = ecDeleteLastChar
ShortCut = 8200
end
item
Command = ecDeleteLastWord
ShortCut = 16392
end
item
Command = ecUndo
ShortCut = 32776
end
item
Command = ecRedo
ShortCut = 40968
end
item
Command = ecLineBreak
ShortCut = 13
end
item
Command = ecSelectAll
ShortCut = 16449
end
item
Command = ecCopy
ShortCut = 16451
end
item
Command = ecBlockIndent
ShortCut = 24649
end
item
Command = ecLineBreak
ShortCut = 16461
end
item
Command = ecInsertLine
ShortCut = 16462
end
item
Command = ecDeleteWord
ShortCut = 16468
end
item
Command = ecBlockUnindent
ShortCut = 24661
end
item
Command = ecPaste
ShortCut = 16470
end
item
Command = ecCut
ShortCut = 16472
end
item
Command = ecDeleteLine
ShortCut = 16473
end
item
Command = ecDeleteEOL
ShortCut = 24665
end
item
Command = ecUndo
ShortCut = 16474
end
item
Command = ecRedo
ShortCut = 24666
end
item
Command = ecGotoMarker0
ShortCut = 16432
end
item
Command = ecGotoMarker1
ShortCut = 16433
end
item
Command = ecGotoMarker2
ShortCut = 16434
end
item
Command = ecGotoMarker3
ShortCut = 16435
end
item
Command = ecGotoMarker4
ShortCut = 16436
end
item
Command = ecGotoMarker5
ShortCut = 16437
end
item
Command = ecGotoMarker6
ShortCut = 16438
end
item
Command = ecGotoMarker7
ShortCut = 16439
end
item
Command = ecGotoMarker8
ShortCut = 16440
end
item
Command = ecGotoMarker9
ShortCut = 16441
end
item
Command = ecSetMarker0
ShortCut = 24624
end
item
Command = ecSetMarker1
ShortCut = 24625
end
item
Command = ecSetMarker2
ShortCut = 24626
end
item
Command = ecSetMarker3
ShortCut = 24627
end
item
Command = ecSetMarker4
ShortCut = 24628
end
item
Command = ecSetMarker5
ShortCut = 24629
end
item
Command = ecSetMarker6
ShortCut = 24630
end
item
Command = ecSetMarker7
ShortCut = 24631
end
item
Command = ecSetMarker8
ShortCut = 24632
end
item
Command = ecSetMarker9
ShortCut = 24633
end
item
Command = EcFoldLevel1
ShortCut = 41009
end
item
Command = EcFoldLevel2
ShortCut = 41010
end
item
Command = EcFoldLevel3
ShortCut = 41011
end
item
Command = EcFoldLevel4
ShortCut = 41012
end
item
Command = EcFoldLevel5
ShortCut = 41013
end
item
Command = EcFoldLevel6
ShortCut = 41014
end
item
Command = EcFoldLevel7
ShortCut = 41015
end
item
Command = EcFoldLevel8
ShortCut = 41016
end
item
Command = EcFoldLevel9
ShortCut = 41017
end
item
Command = EcFoldLevel0
ShortCut = 41008
end
item
Command = EcFoldCurrent
ShortCut = 41005
end
item
Command = EcUnFoldCurrent
ShortCut = 41003
end
item
Command = EcToggleMarkupWord
ShortCut = 32845
end
item
Command = ecNormalSelect
ShortCut = 24654
end
item
Command = ecColumnSelect
ShortCut = 24643
end
item
Command = ecLineSelect
ShortCut = 24652
end
item
Command = ecTab
ShortCut = 9
end
item
Command = ecShiftTab
ShortCut = 8201
end
item
Command = ecMatchBracket
ShortCut = 24642
end
item
Command = ecColSelUp
ShortCut = 40998
end
item
Command = ecColSelDown
ShortCut = 41000
end
item
Command = ecColSelLeft
ShortCut = 40997
end
item
Command = ecColSelRight
ShortCut = 40999
end
item
Command = ecColSelPageDown
ShortCut = 40994
end
item
Command = ecColSelPageBottom
ShortCut = 57378
end
item
Command = ecColSelPageUp
ShortCut = 40993
end
item
Command = ecColSelPageTop
ShortCut = 57377
end
item
Command = ecColSelLineStart
ShortCut = 40996
end
item
Command = ecColSelLineEnd
ShortCut = 40995
end
item
Command = ecColSelEditorTop
ShortCut = 57380
end
item
Command = ecColSelEditorBottom
ShortCut = 57379
end>
MouseActions = <>
MouseTextActions = <>
MouseSelActions = <>
Lines.Strings = (
''
)
Options = [eoAutoIndent, eoBracketHighlight, eoEnhanceHomeKey, eoGroupUndo, eoHalfPageScroll, eoHideRightMargin, eoSmartTabs, eoTabsToSpaces, eoTrimTrailingSpaces, eoAltSetsColumnMode]
Options2 = [eoEnhanceEndKey, eoFoldedCopyPaste, eoOverwriteBlock, eoColorSelectionTillEol]
MouseOptions = [emAltSetsColumnMode, emCtrlWheelZoom]
VisibleSpecialChars = [vscSpace, vscTabAtLast]
ReadOnly = True
RightEdge = 0
ScrollBars = ssAutoBoth
SelectedColor.BackPriority = 50
SelectedColor.ForePriority = 50
SelectedColor.FramePriority = 50
...
...
@@ -196,69 +1062,502 @@ object PreviewClassCode: TPreviewClassCode
inline SynLeftGutterPartList1: TSynGutterPartList
object SynGutterMarks1: TSynGutterMarks
Width = 24
Visible = False
MouseActions = <>
end
object SynGutterLineNumber1: TSynGutterLineNumber
Width = 17
MouseActions = <>
MarkupInfo.Background = clBtnFace
MarkupInfo.Foreground = clNone
DigitCount = 2
ShowOnlyLineNumbersMultiplesOf = 1
ZeroStart = False
LeadingZeros = False
end
object SynGutterChanges1: TSynGutterChanges
Width = 4
MouseActions = <>
ModifiedColor = 59900
SavedColor = clGreen
end
object SynGutterSeparator1: TSynGutterSeparator
Width = 2
MouseActions = <>
MarkupInfo.Background = clWhite
MarkupInfo.Foreground = clGray
end
object SynGutterCodeFolding1: TSynGutterCodeFolding
Visible = False
MouseActions = <>
MarkupInfo.Background = clNone
MarkupInfo.Foreground = clGray
MouseActionsExpanded = <>
MouseActionsCollapsed = <>
end
end
end
end
object TabSheet5: TTabSheet
Caption = 'C#'
ClientHeight = 506
ClientWidth = 781
ImageIndex = 2
inline mem_ClassCSharp: TSynEdit
Left = 0
Height = 506
Top = 0
Width = 781
Align = alClient
Color = clWindow
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Courier New'
Font.Pitch = fpFixed
Font.Quality = fqNonAntialiased
ParentColor = False
ParentFont = False
TabOrder = 0
BorderStyle = bsNone
Gutter.Width = 23
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
Highlighter = SynFreePascalSyn1
Keystrokes = <
item
Command = ecUp
ShortCut = 38
end
item
Command = ecSelUp
ShortCut = 8230
end
item
Command = ecScrollUp
ShortCut = 16422
end
item
Command = ecDown
ShortCut = 40
end
item
Command = ecSelDown
ShortCut = 8232
end
item
Command = ecScrollDown
ShortCut = 16424
end
item
Command = ecLeft
ShortCut = 37
end
item
Command = ecSelLeft
ShortCut = 8229
end
item
Command = ecWordLeft
ShortCut = 16421
end
item
Command = ecSelWordLeft
ShortCut = 24613
end
item
Command = ecRight
ShortCut = 39
end
item
Command = ecSelRight
ShortCut = 8231
end
item
Command = ecWordRight
ShortCut = 16423
end
item
Command = ecSelWordRight
ShortCut = 24615
end
item
Command = ecPageDown
ShortCut = 34
end
item
Command = ecSelPageDown
ShortCut = 8226
end
item
Command = ecPageBottom
ShortCut = 16418
end
item
Command = ecSelPageBottom
ShortCut = 24610
end
item
Command = ecPageUp
ShortCut = 33
end
item
Command = ecSelPageUp
ShortCut = 8225
end
item
Command = ecPageTop
ShortCut = 16417
end
item
Command = ecSelPageTop
ShortCut = 24609
end
item
Command = ecLineStart
ShortCut = 36
end
item
Command = ecSelLineStart
ShortCut = 8228
end
item
Command = ecEditorTop
ShortCut = 16420
end
item
Command = ecSelEditorTop
ShortCut = 24612
end
item
Command = ecLineEnd
ShortCut = 35
end
item
Command = ecSelLineEnd
ShortCut = 8227
end
item
Command = ecEditorBottom
ShortCut = 16419
end
item
Command = ecSelEditorBottom
ShortCut = 24611
end
item
Command = ecToggleMode
ShortCut = 45
end
item
Command = ecCopy
ShortCut = 16429
end
item
Command = ecPaste
ShortCut = 8237
end
item
Command = ecDeleteChar
ShortCut = 46
end
item
Command = ecCut
ShortCut = 8238
end
item
Command = ecDeleteLastChar
ShortCut = 8
end
item
Command = ecDeleteLastChar
ShortCut = 8200
end
item
Command = ecDeleteLastWord
ShortCut = 16392
end
item
Command = ecUndo
ShortCut = 32776
end
item
Command = ecRedo
ShortCut = 40968
end
item
Command = ecLineBreak
ShortCut = 13
end
item
Command = ecSelectAll
ShortCut = 16449
end
item
Command = ecCopy
ShortCut = 16451
end
item
Command = ecBlockIndent
ShortCut = 24649
end
item
Command = ecLineBreak
ShortCut = 16461
end
item
Command = ecInsertLine
ShortCut = 16462
end
item
Command = ecDeleteWord
ShortCut = 16468
end
item
Command = ecBlockUnindent
ShortCut = 24661
end
item
Command = ecPaste
ShortCut = 16470
end
item
Command = ecCut
ShortCut = 16472
end
item
Command = ecDeleteLine
ShortCut = 16473
end
item
Command = ecDeleteEOL
ShortCut = 24665
end
item
Command = ecUndo
ShortCut = 16474
end
item
Command = ecRedo
ShortCut = 24666
end
item
Command = ecGotoMarker0
ShortCut = 16432
end
item
Command = ecGotoMarker1
ShortCut = 16433
end
item
Command = ecGotoMarker2
ShortCut = 16434
end
item
Command = ecGotoMarker3
ShortCut = 16435
end
item
Command = ecGotoMarker4
ShortCut = 16436
end
item
Command = ecGotoMarker5
ShortCut = 16437
end
item
Command = ecGotoMarker6
ShortCut = 16438
end
item
Command = ecGotoMarker7
ShortCut = 16439
end
item
Command = ecGotoMarker8
ShortCut = 16440
end
item
Command = ecGotoMarker9
ShortCut = 16441
end
item
Command = ecSetMarker0
ShortCut = 24624
end
item
Command = ecSetMarker1
ShortCut = 24625
end
item
Command = ecSetMarker2
ShortCut = 24626
end
item
Command = ecSetMarker3
ShortCut = 24627
end
item
Command = ecSetMarker4
ShortCut = 24628
end
item
Command = ecSetMarker5
ShortCut = 24629
end
item
Command = ecSetMarker6
ShortCut = 24630
end
item
Command = ecSetMarker7
ShortCut = 24631
end
item
Command = ecSetMarker8
ShortCut = 24632
end
item
Command = ecSetMarker9
ShortCut = 24633
end
item
Command = EcFoldLevel1
ShortCut = 41009
end
item
Command = EcFoldLevel2
ShortCut = 41010
end
item
Command = EcFoldLevel3
ShortCut = 41011
end
item
Command = EcFoldLevel4
ShortCut = 41012
end
item
Command = EcFoldLevel5
ShortCut = 41013
end
item
Command = EcFoldLevel6
ShortCut = 41014
end
item
Command = EcFoldLevel7
ShortCut = 41015
end
item
Command = EcFoldLevel8
ShortCut = 41016
end
item
Command = EcFoldLevel9
ShortCut = 41017
end
item
Command = EcFoldLevel0
ShortCut = 41008
end
item
Command = EcFoldCurrent
ShortCut = 41005
end
item
Command = EcUnFoldCurrent
ShortCut = 41003
end
item
Command = EcToggleMarkupWord
ShortCut = 32845
end
item
Command = ecNormalSelect
ShortCut = 24654
end
item
Command = ecColumnSelect
ShortCut = 24643
end
item
Command = ecLineSelect
ShortCut = 24652
end
item
Command = ecTab
ShortCut = 9
end
item
Command = ecShiftTab
ShortCut = 8201
end
item
Command = ecMatchBracket
ShortCut = 24642
end
item
Command = ecColSelUp
ShortCut = 40998
end
item
Command = ecColSelDown
ShortCut = 41000
end
object SynGutterLineNumber1: TSynGutterLineNumber
Width = 17
MouseActions = <>
MarkupInfo.Background = clBtnFace
MarkupInfo.Foreground = clNone
DigitCount = 2
ShowOnlyLineNumbersMultiplesOf = 1
ZeroStart = False
LeadingZeros = False
item
Command = ecColSelLeft
ShortCut = 40997
end
object SynGutterChanges1: TSynGutterChanges
Width = 4
MouseActions = <>
ModifiedColor = 59900
SavedColor = clGreen
item
Command = ecColSelRight
ShortCut = 40999
end
object SynGutterSeparator1: TSynGutterSeparator
Width = 2
MouseActions = <>
MarkupInfo.Background = clWhite
MarkupInfo.Foreground = clGray
item
Command = ecColSelPageDown
ShortCut = 40994
end
object SynGutterCodeFolding1: TSynGutterCodeFolding
MouseActions = <>
MarkupInfo.Background = clNone
MarkupInfo.Foreground = clGray
MouseActionsExpanded = <>
MouseActionsCollapsed = <>
item
Command = ecColSelPageBottom
ShortCut = 57378
end
item
Command = ecColSelPageUp
ShortCut = 40993
end
item
Command = ecColSelPageTop
ShortCut = 57377
end
item
Command = ecColSelLineStart
ShortCut = 40996
end
object TabSheet5: TTabSheet
Caption = 'C#'
ClientHeight = 453
ClientWidth = 785
ImageIndex = 2
inline mem_ClassCSharp: TSynEdit
Left = 0
Height = 453
Top = 0
Width = 785
Align = alClient
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Courier New'
Font.Pitch = fpFixed
Font.Quality = fqNonAntialiased
ParentColor = False
ParentFont = False
TabOrder = 0
Gutter.Width = 57
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
Keystrokes = <>
item
Command = ecColSelLineEnd
ShortCut = 40995
end
item
Command = ecColSelEditorTop
ShortCut = 57380
end
item
Command = ecColSelEditorBottom
ShortCut = 57379
end>
MouseActions = <>
MouseTextActions = <>
MouseSelActions = <>
Lines.Strings = (
''
)
Options = [eoAutoIndent, eoBracketHighlight, eoEnhanceHomeKey, eoGroupUndo, eoHalfPageScroll, eoHideRightMargin, eoSmartTabs, eoTabsToSpaces, eoTrimTrailingSpaces, eoAltSetsColumnMode]
Options2 = [eoEnhanceEndKey, eoFoldedCopyPaste, eoOverwriteBlock, eoColorSelectionTillEol]
MouseOptions = [emAltSetsColumnMode, emCtrlWheelZoom]
VisibleSpecialChars = [vscSpace, vscTabAtLast]
ReadOnly = True
RightEdge = 0
ScrollBars = ssAutoBoth
SelectedColor.BackPriority = 50
SelectedColor.ForePriority = 50
SelectedColor.FramePriority = 50
...
...
@@ -280,6 +1579,7 @@ object PreviewClassCode: TPreviewClassCode
inline SynLeftGutterPartList1: TSynGutterPartList
object SynGutterMarks1: TSynGutterMarks
Width = 24
Visible = False
MouseActions = <>
end
object SynGutterLineNumber1: TSynGutterLineNumber
...
...
@@ -305,6 +1605,7 @@ object PreviewClassCode: TPreviewClassCode
MarkupInfo.Foreground = clGray
end
object SynGutterCodeFolding1: TSynGutterCodeFolding
Visible = False
MouseActions = <>
MarkupInfo.Background = clNone
MarkupInfo.Foreground = clGray
...
...
@@ -316,28 +1617,29 @@ object PreviewClassCode: TPreviewClassCode
end
object TabSheet6: TTabSheet
Caption = 'SQL'
ClientHeight =
453
ClientWidth = 78
5
ClientHeight =
506
ClientWidth = 78
1
ImageIndex = 3
object PageControl1: TPageControl
Left = 0
Height =
453
Height =
506
Top = 0
Width = 78
5
Width = 78
1
ActivePage = TabSheet10
Align = alClient
TabIndex = 0
TabOrder = 0
object TabSheet10: TTabSheet
Caption = 'SQL Server'
ClientHeight = 4
14
ClientWidth = 77
9
ClientHeight = 4
78
ClientWidth = 77
1
inline mem_ClassSQL: TSynEdit
Left = 0
Height = 4
14
Height = 4
78
Top = 0
Width = 77
9
Width = 77
1
Align = alClient
Color = clWindow
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Courier New'
...
...
@@ -346,16 +1648,446 @@ object PreviewClassCode: TPreviewClassCode
ParentColor = False
ParentFont = False
TabOrder = 0
Gutter.Width = 57
BorderStyle = bsNone
Gutter.Width = 23
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
Keystrokes = <>
Highlighter = SynSQLSyn1
Keystrokes = <
item
Command = ecUp
ShortCut = 38
end
item
Command = ecSelUp
ShortCut = 8230
end
item
Command = ecScrollUp
ShortCut = 16422
end
item
Command = ecDown
ShortCut = 40
end
item
Command = ecSelDown
ShortCut = 8232
end
item
Command = ecScrollDown
ShortCut = 16424
end
item
Command = ecLeft
ShortCut = 37
end
item
Command = ecSelLeft
ShortCut = 8229
end
item
Command = ecWordLeft
ShortCut = 16421
end
item
Command = ecSelWordLeft
ShortCut = 24613
end
item
Command = ecRight
ShortCut = 39
end
item
Command = ecSelRight
ShortCut = 8231
end
item
Command = ecWordRight
ShortCut = 16423
end
item
Command = ecSelWordRight
ShortCut = 24615
end
item
Command = ecPageDown
ShortCut = 34
end
item
Command = ecSelPageDown
ShortCut = 8226
end
item
Command = ecPageBottom
ShortCut = 16418
end
item
Command = ecSelPageBottom
ShortCut = 24610
end
item
Command = ecPageUp
ShortCut = 33
end
item
Command = ecSelPageUp
ShortCut = 8225
end
item
Command = ecPageTop
ShortCut = 16417
end
item
Command = ecSelPageTop
ShortCut = 24609
end
item
Command = ecLineStart
ShortCut = 36
end
item
Command = ecSelLineStart
ShortCut = 8228
end
item
Command = ecEditorTop
ShortCut = 16420
end
item
Command = ecSelEditorTop
ShortCut = 24612
end
item
Command = ecLineEnd
ShortCut = 35
end
item
Command = ecSelLineEnd
ShortCut = 8227
end
item
Command = ecEditorBottom
ShortCut = 16419
end
item
Command = ecSelEditorBottom
ShortCut = 24611
end
item
Command = ecToggleMode
ShortCut = 45
end
item
Command = ecCopy
ShortCut = 16429
end
item
Command = ecPaste
ShortCut = 8237
end
item
Command = ecDeleteChar
ShortCut = 46
end
item
Command = ecCut
ShortCut = 8238
end
item
Command = ecDeleteLastChar
ShortCut = 8
end
item
Command = ecDeleteLastChar
ShortCut = 8200
end
item
Command = ecDeleteLastWord
ShortCut = 16392
end
item
Command = ecUndo
ShortCut = 32776
end
item
Command = ecRedo
ShortCut = 40968
end
item
Command = ecLineBreak
ShortCut = 13
end
item
Command = ecSelectAll
ShortCut = 16449
end
item
Command = ecCopy
ShortCut = 16451
end
item
Command = ecBlockIndent
ShortCut = 24649
end
item
Command = ecLineBreak
ShortCut = 16461
end
item
Command = ecInsertLine
ShortCut = 16462
end
item
Command = ecDeleteWord
ShortCut = 16468
end
item
Command = ecBlockUnindent
ShortCut = 24661
end
item
Command = ecPaste
ShortCut = 16470
end
item
Command = ecCut
ShortCut = 16472
end
item
Command = ecDeleteLine
ShortCut = 16473
end
item
Command = ecDeleteEOL
ShortCut = 24665
end
item
Command = ecUndo
ShortCut = 16474
end
item
Command = ecRedo
ShortCut = 24666
end
item
Command = ecGotoMarker0
ShortCut = 16432
end
item
Command = ecGotoMarker1
ShortCut = 16433
end
item
Command = ecGotoMarker2
ShortCut = 16434
end
item
Command = ecGotoMarker3
ShortCut = 16435
end
item
Command = ecGotoMarker4
ShortCut = 16436
end
item
Command = ecGotoMarker5
ShortCut = 16437
end
item
Command = ecGotoMarker6
ShortCut = 16438
end
item
Command = ecGotoMarker7
ShortCut = 16439
end
item
Command = ecGotoMarker8
ShortCut = 16440
end
item
Command = ecGotoMarker9
ShortCut = 16441
end
item
Command = ecSetMarker0
ShortCut = 24624
end
item
Command = ecSetMarker1
ShortCut = 24625
end
item
Command = ecSetMarker2
ShortCut = 24626
end
item
Command = ecSetMarker3
ShortCut = 24627
end
item
Command = ecSetMarker4
ShortCut = 24628
end
item
Command = ecSetMarker5
ShortCut = 24629
end
item
Command = ecSetMarker6
ShortCut = 24630
end
item
Command = ecSetMarker7
ShortCut = 24631
end
item
Command = ecSetMarker8
ShortCut = 24632
end
item
Command = ecSetMarker9
ShortCut = 24633
end
item
Command = EcFoldLevel1
ShortCut = 41009
end
item
Command = EcFoldLevel2
ShortCut = 41010
end
item
Command = EcFoldLevel3
ShortCut = 41011
end
item
Command = EcFoldLevel4
ShortCut = 41012
end
item
Command = EcFoldLevel5
ShortCut = 41013
end
item
Command = EcFoldLevel6
ShortCut = 41014
end
item
Command = EcFoldLevel7
ShortCut = 41015
end
item
Command = EcFoldLevel8
ShortCut = 41016
end
item
Command = EcFoldLevel9
ShortCut = 41017
end
item
Command = EcFoldLevel0
ShortCut = 41008
end
item
Command = EcFoldCurrent
ShortCut = 41005
end
item
Command = EcUnFoldCurrent
ShortCut = 41003
end
item
Command = EcToggleMarkupWord
ShortCut = 32845
end
item
Command = ecNormalSelect
ShortCut = 24654
end
item
Command = ecColumnSelect
ShortCut = 24643
end
item
Command = ecLineSelect
ShortCut = 24652
end
item
Command = ecTab
ShortCut = 9
end
item
Command = ecShiftTab
ShortCut = 8201
end
item
Command = ecMatchBracket
ShortCut = 24642
end
item
Command = ecColSelUp
ShortCut = 40998
end
item
Command = ecColSelDown
ShortCut = 41000
end
item
Command = ecColSelLeft
ShortCut = 40997
end
item
Command = ecColSelRight
ShortCut = 40999
end
item
Command = ecColSelPageDown
ShortCut = 40994
end
item
Command = ecColSelPageBottom
ShortCut = 57378
end
item
Command = ecColSelPageUp
ShortCut = 40993
end
item
Command = ecColSelPageTop
ShortCut = 57377
end
item
Command = ecColSelLineStart
ShortCut = 40996
end
item
Command = ecColSelLineEnd
ShortCut = 40995
end
item
Command = ecColSelEditorTop
ShortCut = 57380
end
item
Command = ecColSelEditorBottom
ShortCut = 57379
end>
MouseActions = <>
MouseTextActions = <>
MouseSelActions = <>
Lines.Strings = (
''
)
Options = [eoAutoIndent, eoBracketHighlight, eoEnhanceHomeKey, eoGroupUndo, eoHalfPageScroll, eoHideRightMargin, eoSmartTabs, eoTabsToSpaces, eoTrimTrailingSpaces, eoAltSetsColumnMode]
Options2 = [eoEnhanceEndKey, eoFoldedCopyPaste, eoOverwriteBlock, eoColorSelectionTillEol]
MouseOptions = [emAltSetsColumnMode, emCtrlWheelZoom]
VisibleSpecialChars = [vscSpace, vscTabAtLast]
ReadOnly = True
RightEdge = 0
ScrollBars = ssAutoBoth
SelectedColor.BackPriority = 50
SelectedColor.ForePriority = 50
SelectedColor.FramePriority = 50
...
...
@@ -377,6 +2109,7 @@ object PreviewClassCode: TPreviewClassCode
inline SynLeftGutterPartList1: TSynGutterPartList
object SynGutterMarks1: TSynGutterMarks
Width = 24
Visible = False
MouseActions = <>
end
object SynGutterLineNumber1: TSynGutterLineNumber
...
...
@@ -402,6 +2135,7 @@ object PreviewClassCode: TPreviewClassCode
MarkupInfo.Foreground = clGray
end
object SynGutterCodeFolding1: TSynGutterCodeFolding
Visible = False
MouseActions = <>
MarkupInfo.Background = clNone
MarkupInfo.Foreground = clGray
...
...
@@ -413,15 +2147,16 @@ object PreviewClassCode: TPreviewClassCode
end
object TabSheet14: TTabSheet
Caption = 'Oracle'
ClientHeight =
0
ClientWidth =
0
ClientHeight =
478
ClientWidth =
771
ImageIndex = 1
inline mem_ClassOracle: TSynEdit
Left = 0
Height = 4
41
Height = 4
78
Top = 0
Width = 77
3
Width = 77
1
Align = alClient
Color = clWindow
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Courier New'
...
...
@@ -430,16 +2165,446 @@ object PreviewClassCode: TPreviewClassCode
ParentColor = False
ParentFont = False
TabOrder = 0
Gutter.Width = 57
BorderStyle = bsNone
Gutter.Width = 23
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
Keystrokes = <>
Highlighter = SynSQLSyn1
Keystrokes = <
item
Command = ecUp
ShortCut = 38
end
item
Command = ecSelUp
ShortCut = 8230
end
item
Command = ecScrollUp
ShortCut = 16422
end
item
Command = ecDown
ShortCut = 40
end
item
Command = ecSelDown
ShortCut = 8232
end
item
Command = ecScrollDown
ShortCut = 16424
end
item
Command = ecLeft
ShortCut = 37
end
item
Command = ecSelLeft
ShortCut = 8229
end
item
Command = ecWordLeft
ShortCut = 16421
end
item
Command = ecSelWordLeft
ShortCut = 24613
end
item
Command = ecRight
ShortCut = 39
end
item
Command = ecSelRight
ShortCut = 8231
end
item
Command = ecWordRight
ShortCut = 16423
end
item
Command = ecSelWordRight
ShortCut = 24615
end
item
Command = ecPageDown
ShortCut = 34
end
item
Command = ecSelPageDown
ShortCut = 8226
end
item
Command = ecPageBottom
ShortCut = 16418
end
item
Command = ecSelPageBottom
ShortCut = 24610
end
item
Command = ecPageUp
ShortCut = 33
end
item
Command = ecSelPageUp
ShortCut = 8225
end
item
Command = ecPageTop
ShortCut = 16417
end
item
Command = ecSelPageTop
ShortCut = 24609
end
item
Command = ecLineStart
ShortCut = 36
end
item
Command = ecSelLineStart
ShortCut = 8228
end
item
Command = ecEditorTop
ShortCut = 16420
end
item
Command = ecSelEditorTop
ShortCut = 24612
end
item
Command = ecLineEnd
ShortCut = 35
end
item
Command = ecSelLineEnd
ShortCut = 8227
end
item
Command = ecEditorBottom
ShortCut = 16419
end
item
Command = ecSelEditorBottom
ShortCut = 24611
end
item
Command = ecToggleMode
ShortCut = 45
end
item
Command = ecCopy
ShortCut = 16429
end
item
Command = ecPaste
ShortCut = 8237
end
item
Command = ecDeleteChar
ShortCut = 46
end
item
Command = ecCut
ShortCut = 8238
end
item
Command = ecDeleteLastChar
ShortCut = 8
end
item
Command = ecDeleteLastChar
ShortCut = 8200
end
item
Command = ecDeleteLastWord
ShortCut = 16392
end
item
Command = ecUndo
ShortCut = 32776
end
item
Command = ecRedo
ShortCut = 40968
end
item
Command = ecLineBreak
ShortCut = 13
end
item
Command = ecSelectAll
ShortCut = 16449
end
item
Command = ecCopy
ShortCut = 16451
end
item
Command = ecBlockIndent
ShortCut = 24649
end
item
Command = ecLineBreak
ShortCut = 16461
end
item
Command = ecInsertLine
ShortCut = 16462
end
item
Command = ecDeleteWord
ShortCut = 16468
end
item
Command = ecBlockUnindent
ShortCut = 24661
end
item
Command = ecPaste
ShortCut = 16470
end
item
Command = ecCut
ShortCut = 16472
end
item
Command = ecDeleteLine
ShortCut = 16473
end
item
Command = ecDeleteEOL
ShortCut = 24665
end
item
Command = ecUndo
ShortCut = 16474
end
item
Command = ecRedo
ShortCut = 24666
end
item
Command = ecGotoMarker0
ShortCut = 16432
end
item
Command = ecGotoMarker1
ShortCut = 16433
end
item
Command = ecGotoMarker2
ShortCut = 16434
end
item
Command = ecGotoMarker3
ShortCut = 16435
end
item
Command = ecGotoMarker4
ShortCut = 16436
end
item
Command = ecGotoMarker5
ShortCut = 16437
end
item
Command = ecGotoMarker6
ShortCut = 16438
end
item
Command = ecGotoMarker7
ShortCut = 16439
end
item
Command = ecGotoMarker8
ShortCut = 16440
end
item
Command = ecGotoMarker9
ShortCut = 16441
end
item
Command = ecSetMarker0
ShortCut = 24624
end
item
Command = ecSetMarker1
ShortCut = 24625
end
item
Command = ecSetMarker2
ShortCut = 24626
end
item
Command = ecSetMarker3
ShortCut = 24627
end
item
Command = ecSetMarker4
ShortCut = 24628
end
item
Command = ecSetMarker5
ShortCut = 24629
end
item
Command = ecSetMarker6
ShortCut = 24630
end
item
Command = ecSetMarker7
ShortCut = 24631
end
item
Command = ecSetMarker8
ShortCut = 24632
end
item
Command = ecSetMarker9
ShortCut = 24633
end
item
Command = EcFoldLevel1
ShortCut = 41009
end
item
Command = EcFoldLevel2
ShortCut = 41010
end
item
Command = EcFoldLevel3
ShortCut = 41011
end
item
Command = EcFoldLevel4
ShortCut = 41012
end
item
Command = EcFoldLevel5
ShortCut = 41013
end
item
Command = EcFoldLevel6
ShortCut = 41014
end
item
Command = EcFoldLevel7
ShortCut = 41015
end
item
Command = EcFoldLevel8
ShortCut = 41016
end
item
Command = EcFoldLevel9
ShortCut = 41017
end
item
Command = EcFoldLevel0
ShortCut = 41008
end
item
Command = EcFoldCurrent
ShortCut = 41005
end
item
Command = EcUnFoldCurrent
ShortCut = 41003
end
item
Command = EcToggleMarkupWord
ShortCut = 32845
end
item
Command = ecNormalSelect
ShortCut = 24654
end
item
Command = ecColumnSelect
ShortCut = 24643
end
item
Command = ecLineSelect
ShortCut = 24652
end
item
Command = ecTab
ShortCut = 9
end
item
Command = ecShiftTab
ShortCut = 8201
end
item
Command = ecMatchBracket
ShortCut = 24642
end
item
Command = ecColSelUp
ShortCut = 40998
end
item
Command = ecColSelDown
ShortCut = 41000
end
item
Command = ecColSelLeft
ShortCut = 40997
end
item
Command = ecColSelRight
ShortCut = 40999
end
item
Command = ecColSelPageDown
ShortCut = 40994
end
item
Command = ecColSelPageBottom
ShortCut = 57378
end
item
Command = ecColSelPageUp
ShortCut = 40993
end
item
Command = ecColSelPageTop
ShortCut = 57377
end
item
Command = ecColSelLineStart
ShortCut = 40996
end
item
Command = ecColSelLineEnd
ShortCut = 40995
end
item
Command = ecColSelEditorTop
ShortCut = 57380
end
item
Command = ecColSelEditorBottom
ShortCut = 57379
end>
MouseActions = <>
MouseTextActions = <>
MouseSelActions = <>
Lines.Strings = (
''
)
Options = [eoAutoIndent, eoBracketHighlight, eoEnhanceHomeKey, eoGroupUndo, eoHalfPageScroll, eoHideRightMargin, eoSmartTabs, eoTabsToSpaces, eoTrimTrailingSpaces, eoAltSetsColumnMode]
Options2 = [eoEnhanceEndKey, eoFoldedCopyPaste, eoOverwriteBlock, eoColorSelectionTillEol]
MouseOptions = [emAltSetsColumnMode, emCtrlWheelZoom]
VisibleSpecialChars = [vscSpace, vscTabAtLast]
ReadOnly = True
RightEdge = 0
ScrollBars = ssAutoBoth
SelectedColor.BackPriority = 50
SelectedColor.ForePriority = 50
SelectedColor.FramePriority = 50
...
...
@@ -461,6 +2626,7 @@ object PreviewClassCode: TPreviewClassCode
inline SynLeftGutterPartList1: TSynGutterPartList
object SynGutterMarks1: TSynGutterMarks
Width = 24
Visible = False
MouseActions = <>
end
object SynGutterLineNumber1: TSynGutterLineNumber
...
...
@@ -486,6 +2652,7 @@ object PreviewClassCode: TPreviewClassCode
MarkupInfo.Foreground = clGray
end
object SynGutterCodeFolding1: TSynGutterCodeFolding
Visible = False
MouseActions = <>
MarkupInfo.Background = clNone
MarkupInfo.Foreground = clGray
...
...
@@ -501,4 +2668,24 @@ object PreviewClassCode: TPreviewClassCode
end
end
end
object SynFreePascalSyn1: TSynFreePascalSyn
Enabled = False
CompilerMode = pcmObjFPC
NestedComments = True
left = 383
top = 19
end
object SynJavaSyn1: TSynJavaSyn
DefaultFilter = 'Java Files (*.java)|*.java'
Enabled = False
left = 503
top = 19
end
object SynSQLSyn1: TSynSQLSyn
DefaultFilter = 'SQL Files (*.sql)|*.sql'
Enabled = False
SQLDialect = sqlSybase
left = 589
top = 19
end
end
EvoUMLPlugin/src/formMemo.pas
View file @
d36b4459
...
...
@@ -3,29 +3,36 @@ unit formMemo;
interface
uses
Messages
,
SysUtils
,
Variants
,
Classes
,
Graphics
,
Controls
,
Forms
,
Dialogs
,
StdCtrls
,
ExtCtrls
,
ComCtrls
,
SynEdit
;
Messages
,
SysUtils
,
Variants
,
Classes
,
Graphics
,
Controls
,
Forms
,
Dialogs
,
StdCtrls
,
ExtCtrls
,
ComCtrls
,
SynEdit
,
SynHighlighterPas
,
SynHighlighterJava
,
SynHighlighterSQL
;
type
{ TPreviewClassCode }
TPreviewClassCode
=
class
(
TForm
)
Panel2
:
TPanel
;
Panel1
:
TPanel
;
Button1
:
TButton
;
pgc_Main
:
TPageControl
;
mem_ClassJava
:
TSynEdit
;
mem_ClassPascal
:
TSynEdit
;
mem_ClassCSharp
:
TSynEdit
;
mem_ClassSQL
:
TSynEdit
;
mem_ClassOracle
:
TSynEdit
;
SynFreePascalSyn1
:
TSynFreePascalSyn
;
SynJavaSyn1
:
TSynJavaSyn
;
SynSQLSyn1
:
TSynSQLSyn
;
TabSheet1
:
TTabSheet
;
pgc_ClassCode
:
TPageControl
;
TabSheet3
:
TTabSheet
;
mem_ClassPascal
:
TSynEdit
;
TabSheet4
:
TTabSheet
;
mem_ClassJava
:
TSynEdit
;
TabSheet5
:
TTabSheet
;
mem_ClassCSharp
:
TSynEdit
;
TabSheet6
:
TTabSheet
;
PageControl1
:
TPageControl
;
TabSheet10
:
TTabSheet
;
TabSheet14
:
TTabSheet
;
mem_ClassSQL
:
TSynEdit
;
mem_ClassOracle
:
TSynEdit
;
procedure
Button1Click
(
Sender
:
TObject
);
private
{ Private declarations }
...
...
EvoUMLPlugin/src/ituDataBaseLogin.dfm
View file @
d36b4459
object DataBaseLogin: TDataBaseLogin
Left =
2241
Height = 5
43
Top = 2
55
Left =
1480
Height = 5
37
Top = 2
99
Width = 440
BorderIcons = [biSystemMenu]
BorderStyle = bsDialog
Caption = 'Connect to Database Server'
ClientHeight = 5
43
ClientHeight = 5
37
ClientWidth = 440
Color = clBtnFace
OnClose = FormClose
OnShow = FormShow
ParentFont = True
Position = poOwnerFormCenter
LCLVersion = '2.0.0.4'
object GroupBox2: TGroupBox
Left = 8
Height = 208
Top = 288
Width = 424
TabOrder = 11
end
object GroupBox1: TGroupBox
Left = 8
Height = 272
Top = 8
Width = 424
TabOrder = 10
end
object cbODBCD_DSN: TComboBox
Left = 32
Height = 15
Top = 48
Width = 389
ItemHeight = 0
OnChange = cbODBCD_DSNChange
Style = csDropDownList
ClientHeight = 206
ClientWidth = 422
TabOrder = 1
end
object edtUsuario: TLabeledEdit
Left = 21
Height = 22
Top = 398
Left = 15
Height = 43
Top = 95
Width = 400
EditLabel.Height = 16
EditLabel.Height = 19
EditLabel.Width = 400
EditLabel.Caption = 'Usuário'
EditLabel.ParentColor = False
TabOrder = 7
TabOrder = 1
end
object edtPassword: TLabeledEdit
Left = 21
Height = 22
Top = 454
Left = 15
Height = 43
Top = 160
Width = 400
EchoMode = emPassword
EditLabel.Height = 16
EditLabel.Height = 19
EditLabel.Width = 400
EditLabel.Caption = 'Senha'
EditLabel.ParentColor = False
PasswordChar = '*'
TabOrder = 8
TabOrder = 2
end
object cbDialect: TComboBox
Left = 21
Height = 15
Top = 339
Left = 15
Height = 39
Top = 25
Width = 400
ItemHeight = 0
OnChange = cbODBCD_DSNChange
Style = csDropDownList
TabOrder = 6
TabOrder = 0
end
object Label2: TLabel
Left = 21
Height = 16
Top = 320
Width = 45
Left = 15
Height = 19
Top = 5
Width = 48
Caption = 'Dialeto'
ParentColor = False
end
end
object GroupBox1: TGroupBox
Left = 8
Height = 272
Top = 8
Width = 424
ClientHeight = 270
ClientWidth = 422
TabOrder = 0
object cbODBCD_DSN: TComboBox
Left = 26
Height = 39
Top = 48
Width = 389
ItemHeight = 0
OnChange = cbODBCD_DSNChange
Style = csDropDownList
TabOrder = 1
end
object rbDSN: TRadioButton
Left = 16
Height = 18
Left = 10
Height = 24
Top = 16
Width = 115
Width = 130
Caption = 'Selecionar DSN'
Checked = True
OnClick = rbDSNClick
...
...
@@ -91,19 +95,19 @@ object DataBaseLogin: TDataBaseLogin
TabStop = True
end
object rbPersonalizado: TRadioButton
Left = 16
Height = 18
Left = 10
Height = 24
Top = 88
Width = 108
Width = 119
Caption = 'Personalizado'
OnClick = rbPersonalizadoClick
TabOrder = 2
end
object cbODBCD_DRIVERS: TComboBox
Left = 35
Height = 15
Top = 120
Width = 386
Left = 26
Height = 39
Top = 115
Width = 389
Enabled = False
ItemHeight = 0
OnChange = cbODBCD_DSNChange
...
...
@@ -111,56 +115,59 @@ object DataBaseLogin: TDataBaseLogin
TabOrder = 3
end
object edtDatabaseName: TLabeledEdit
Left = 32
Height = 22
Left = 26
Height = 43
Top = 232
Width = 389
EditLabel.Height = 16
EditLabel.Height = 19
EditLabel.Width = 389
EditLabel.Caption = 'Nome do Banco de Dados'
EditLabel.ParentColor = False
Enabled = False
TabOrder = 5
TabOrder = 4
end
object edtServerName: TLabeledEdit
Left = 32
Height = 22
Left = 26
Height = 43
Top = 176
Width = 389
EditLabel.Height = 16
EditLabel.Height = 19
EditLabel.Width = 389
EditLabel.Caption = 'Servidor'
EditLabel.ParentColor = False
Enabled = False
TabOrder = 4
TabOrder = 5
end
end
object Panel2: TPanel
Left = 0
Height = 40
Top =
503
Top =
497
Width = 440
Align = alBottom
ClientHeight = 40
ClientWidth = 440
TabOrder =
9
TabOrder =
2
object BitBtn1: TBitBtn
Left = 2
6
8
Height = 2
5
Top =
7
Width =
75
Left = 2
3
8
Height = 2
7
Top =
5
Width =
93
Anchors = [akTop, akRight]
Caption = 'Ok'
Default = True
Kind = bkOK
ModalResult = 1
OnClick = Button1Click
TabOrder = 0
end
object BitBtn2: TBitBtn
Left = 3
49
Height = 2
5
Top =
7
Width =
75
Left = 3
37
Height = 2
7
Top =
5
Width =
93
Anchors = [akTop, akRight]
Cancel = True
Caption = 'Cancel'
Kind = bkCancel
ModalResult = 2
...
...
EvoUMLPlugin/src/ituExplorerV2.dfm
View file @
d36b4459
object ExplorerV2: TExplorerV2
Left =
2406
Height = 69
5
Top = 1
77
Width = 12
28
Left =
577
Height = 69
6
Top = 1
03
Width = 12
32
Caption = 'Model OQL Query'
ClientHeight = 69
5
ClientWidth = 12
28
ClientHeight = 69
6
ClientWidth = 12
32
Color = clWindow
Icon.Data = {
96A5050000000100060000000000010020002820040066000000101000000100
...
...
@@ -11574,6 +11574,7 @@ object ExplorerV2: TExplorerV2
001FF80000000000001FF80000000000001FFFFFFFFFFFFFFFFFFFFFFFFFFFFF
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
}
KeyPreview = True
OnClose = FormClose
OnCreate = FormCreate
OnDestroy = FormDestroy
...
...
@@ -11581,9 +11582,10 @@ object ExplorerV2: TExplorerV2
ParentFont = True
Position = poMainFormCenter
ShowInTaskBar = stAlways
LCLVersion = '2.0.0.4'
object splVertical: TSplitter
Left = 360
Height = 69
5
Height = 69
6
Top = 0
Width = 5
MinSize = 5
...
...
@@ -11591,56 +11593,56 @@ object ExplorerV2: TExplorerV2
end
object pnlEditor: TPanel
Left = 365
Height = 69
5
Height = 69
6
Top = 0
Width = 86
3
Width = 86
7
Align = alClient
BevelOuter = bvNone
ClientHeight = 69
5
ClientWidth = 86
3
ClientHeight = 69
6
ClientWidth = 86
7
TabOrder = 0
object pnlResult: TPanel
Left = 0
Height = 185
Top = 49
5
Width = 86
3
Top = 49
0
Width = 86
7
Align = alBottom
BevelOuter = bvNone
ClientHeight = 185
ClientWidth = 86
3
ClientWidth = 86
7
TabOrder = 0
object pcResults: TPageControl
Left = 0
Height = 185
Top = 0
Width = 86
3
Width = 86
7
ActivePage = tsError
Align = alClient
ShowTabs = False
TabIndex = 1
TabOrder = 0
object tsQueryResult: TTabSheet
Caption = 'tsQueryResult'
ClientHeight = 158
ClientWidth = 882
TabVisible = False
ClientHeight = 181
ClientWidth = 857
object pcXMLResults: TPageControl
Left = 0
Height = 1
58
Height = 1
81
Top = 0
Width = 8
82
Width = 8
53
ActivePage = tsList
Align = alClient
TabIndex = 0
TabOrder = 0
object tsList: TTabSheet
Caption = 'Result List'
ClientHeight = 1
19
ClientWidth = 8
76
ClientHeight = 1
77
ClientWidth = 8
49
object lvXMLListResult: TListView
Left = 0
Height = 1
31
Height = 1
48
Top = 0
Width = 8
74
Width = 8
43
Align = alClient
BorderStyle = bsNone
Columns = <>
...
...
@@ -11648,25 +11650,26 @@ object ExplorerV2: TExplorerV2
ParentColor = True
ReadOnly = True
RowSelect = True
ScrollBars = ssAutoBoth
TabOrder = 0
ViewStyle = vsReport
end
end
object tsXML: TTabSheet
Caption = 'XML Result'
ClientHeight = 1
31
ClientWidth = 8
74
ClientHeight = 1
77
ClientWidth = 8
49
ImageIndex = 1
object memXMLTextResult: TMemo
Left = 0
Height = 1
31
Height = 1
48
Top = 0
Width = 8
74
Width = 8
43
Align = alClient
BorderStyle = bsNone
ParentColor = True
ReadOnly = True
ScrollBars = ssBoth
ScrollBars = ss
Auto
Both
TabOrder = 0
end
end
...
...
@@ -11674,20 +11677,19 @@ object ExplorerV2: TExplorerV2
end
object tsError: TTabSheet
Caption = 'tsError'
ClientHeight = 1
46
ClientHeight = 1
81
ClientWidth = 857
ImageIndex = 1
TabVisible = False
object memErrorText: TMemo
Left = 0
Height = 1
46
Height = 1
81
Top = 0
Width = 857
Align = alClient
BorderStyle = bsNone
ParentColor = True
ReadOnly = True
ScrollBars = ssBoth
ScrollBars = ss
Auto
Both
TabOrder = 0
end
end
...
...
@@ -11695,28 +11697,31 @@ object ExplorerV2: TExplorerV2
end
object pcEditor: TPageControl
Left = 0
Height = 4
42
Height = 4
37
Top = 48
Width =
498
Width =
502
ActivePage = tsOQL
Align = alClient
MultiLine = True
ParentFont = False
TabIndex = 0
TabOrder = 1
OnChange = pcEditorChange
Options = [nboMultiLine]
object tsOQL: TTabSheet
Caption = 'OQL - Object Query Language'
ClientHeight = 40
3
ClientHeight = 40
4
ClientWidth = 492
inline SynEditOQL: TSynEdit
Left = 0
Height = 40
3
Height = 40
4
Top = 0
Width = 492
Align = alClient
Font.Height = -13
Font.Name = 'Courier New'
Color = clWindow
Font.Color = clWindowText
Font.Height = 13
Font.Name = 'DejaVu Sans Mono'
Font.Pitch = fpFixed
Font.Quality = fqNonAntialiased
ParentColor = False
...
...
@@ -11725,7 +11730,7 @@ object ExplorerV2: TExplorerV2
OnDragDrop = memOQLQuery2DragDrop
OnDragOver = memOQLQuery2DragOver
BorderStyle = bsNone
Gutter.Width =
3
3
Gutter.Width =
2
3
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
...
...
@@ -12222,14 +12227,16 @@ object ExplorerV2: TExplorerV2
end
object tsSQL: TTabSheet
Caption = 'SQL Translation'
ClientHeight = 40
3
ClientHeight = 40
4
ClientWidth = 492
inline SynEditSQL: TSynEdit
Left = 0
Height = 40
3
Height = 40
4
Top = 0
Width = 492
Align = alClient
Color = clWindow
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Courier New'
Font.Pitch = fpFixed
...
...
@@ -12238,7 +12245,7 @@ object ExplorerV2: TExplorerV2
ParentFont = False
TabOrder = 0
BorderStyle = bsNone
Gutter.Width =
3
3
Gutter.Width =
2
3
Gutter.MouseActions = <>
RightGutter.Width = 0
RightGutter.MouseActions = <>
...
...
@@ -12739,18 +12746,18 @@ object ExplorerV2: TExplorerV2
Left = 0
Height = 48
Top = 0
Width = 86
3
Width = 86
7
Align = alTop
AutoSize = True
BevelOuter = bvNone
ClientHeight = 48
ClientWidth = 86
3
ClientWidth = 86
7
TabOrder = 2
object ToolBar1: TToolBar
Left = 0
Height = 48
Top = 0
Width = 86
3
Width = 86
7
ButtonHeight = 40
ButtonWidth = 50
Caption = 'ToolBar1'
...
...
@@ -12802,7 +12809,7 @@ object ExplorerV2: TExplorerV2
Style = tbsCheck
end
object ToolButton8: TToolButton
Left = 35
1
Left = 35
5
Top = 2
Action = XMLQuery
Grouped = True
...
...
@@ -12823,8 +12830,8 @@ object ExplorerV2: TExplorerV2
end
end
object spResultObject: TSplitter
Left =
498
Height = 4
42
Left =
502
Height = 4
37
Top = 48
Width = 5
Align = alRight
...
...
@@ -12832,41 +12839,40 @@ object ExplorerV2: TExplorerV2
ResizeStyle = rsPattern
end
inline OQLObjects: TObjectExplorer
Left = 50
3
Height = 4
42
Left = 50
7
Height = 4
37
Top = 48
Width = 360
Align = alRight
ClientHeight = 4
42
ClientHeight = 4
37
ClientWidth = 360
TabOrder = 4
Visible = False
inherited tvExplorer: TTreeView
Height = 4
42
Height = 4
37
Width = 360
Images = ilModel
ParentColor = True
PopupMenu = pmCopiar
ReadOnly = False
RightClickSelect = True
Options = [tvoAutoItemHeight, tvoHideSelection, tvoKeepCollapsedNodes, tvoRightClickSelect, tvoShowButtons, tvoShowRoot, tvoToolTips, tvoThemedDraw]
Options = [tvoAutoItemHeight, tvoHideSelection, tvoKeepCollapsedNodes, tvoR
eadOnly, tvoR
ightClickSelect, tvoShowButtons, tvoShowRoot, tvoToolTips, tvoThemedDraw]
end
end
object spResultXML: TSplitter
Cursor = crVSplit
Left = 0
Height = 5
Top = 4
90
Width = 86
3
Top = 4
85
Width = 86
7
Align = alBottom
ResizeAnchor = akBottom
ResizeStyle = rsPattern
end
object sbStatusBar: TStatusBar
Left = 0
Height =
15
Top = 6
80
Width = 86
3
Height =
21
Top = 6
75
Width = 86
7
Panels = <
item
Width = 400
...
...
@@ -12886,17 +12892,17 @@ object ExplorerV2: TExplorerV2
end
object pnlModel: TPanel
Left = 0
Height = 69
5
Height = 69
6
Top = 0
Width = 360
Align = alLeft
BevelOuter = bvNone
ClientHeight = 69
5
ClientHeight = 69
6
ClientWidth = 360
TabOrder = 1
object tvModelExplorer: TTreeView
Left = 0
Height = 69
5
Height = 69
6
Top = 0
Width = 360
Align = alClient
...
...
EvoUMLPlugin/src/ituExplorerV2.pas
View file @
d36b4459
...
...
@@ -117,6 +117,8 @@ type
{ Public declarations }
property
MetaModel
:
acMetaModel
read
fMetaModel
write
SetMetaModel
;
property
Util
:
TUtil
read
fUtil
;
property
SQLDialect
:
acAbstractSQLDialect
read
fSQLDialect
;
property
Schema
:
String
read
fSchema
;
end
;
var
...
...
@@ -370,6 +372,7 @@ begin
end
else
begin
pcResults
.
ActivePageIndex
:=
0
;
spResultObject
.
Visible
:=
False
;
pnlResult
.
Visible
:=
True
;
spResultXML
.
Visible
:=
True
;
...
...
EvoUMLPlugin/src/ituOQLExplorerV2.dfm
View file @
d36b4459
object OQLExplorerV2: TOQLExplorerV2
Left =
375
Height = 55
8
Top =
363
Left =
2177
Height = 55
2
Top =
281
Width = 1090
Caption = '
OQLExplorerV2
'
ClientHeight = 55
8
Caption = '
Curio OQL Explorer
'
ClientHeight = 55
2
ClientWidth = 1090
Color = clBtnFace
Font.Color = clWindowText
...
...
@@ -11582,90 +11582,73 @@ object OQLExplorerV2: TOQLExplorerV2
OnCreate = FormCreate
OnResize = FormResize
OnShow = FormShow
LCLVersion = '2.0.2.0'
object pnlActionBar: TPanel
Left = 0
Height = 35
Top = 0
Width = 1090
Align = alTop
BevelOuter = bvNone
TabOrder = 0
end
LCLVersion = '2.0.0.4'
object pcCXOQL: TPageControl
Left = 0
Height = 5
23
Height = 5
17
Top = 35
Width = 1090
ActivePage = tsCXOQL
Align = alClient
TabIndex = 0
TabOrder =
1
TabOrder =
0
object tsCXOQL: TTabSheet
Caption = 'CXOQL'
ClientHeight = 4
97
ClientWidth = 108
2
ClientHeight = 4
89
ClientWidth = 108
0
object pnlCXOQL: TPanel
Left = 0
Height = 4
97
Height = 4
89
Top = 0
Width = 108
2
Width = 108
0
Align = alClient
BevelOuter = bvNone
ClientHeight = 4
97
ClientWidth = 108
2
ClientHeight = 4
89
ClientWidth = 108
0
ParentBackground = False
TabOrder = 0
object splVertical: TSplitter
Left = 2
19
Height = 4
97
Left = 2
74
Height = 4
89
Top = 0
Width =
8
Width =
4
Color = clBtnFace
OnCanResize = splVerticalCanResize
ParentColor = False
end
object pnlOQLList: TPanel
Left = 0
Height = 4
97
Height = 4
89
Top = 0
Width = 2
19
Width = 2
74
Align = alLeft
BevelOuter = bvNone
ClientHeight = 497
ClientWidth = 219
TabOrder = 0
object pnlOQLButtons: TPanel
Left = 0
Height = 35
Top = 0
Width = 219
Align = alTop
BevelOuter = bvNone
ClientHeight = 489
ClientWidth = 274
TabOrder = 0
end
object pnlList: TPanel
Left = 0
Height = 46
2
Top =
35
Width = 2
19
Height = 46
3
Top =
26
Width = 2
74
Align = alClient
BevelOuter = bvNone
ClientHeight = 46
2
ClientWidth = 2
19
TabOrder =
1
ClientHeight = 46
3
ClientWidth = 2
74
TabOrder =
0
object lvOQLList: TListView
Left = 0
Height = 37
4
Height = 37
5
Top = 0
Width = 2
19
Width = 2
74
Align = alClient
Columns = <
item
AutoSize = True
Caption = 'OQL Name'
Width =
74
Width =
272
end>
ScrollBars = ssAutoBoth
SmallImages = ilOQLState
TabOrder = 0
ViewStyle = vsReport
...
...
@@ -11674,30 +11657,51 @@ object OQLExplorerV2: TOQLExplorerV2
object memError: TMemo
Left = 0
Height = 88
Top = 37
4
Width = 2
19
Top = 37
5
Width = 2
74
Align = alBottom
Color = clBtnFace
ReadOnly = True
TabOrder = 1
end
end
object ToolBar2: TToolBar
Left = 0
Height = 26
Top = 0
Width = 274
Caption = 'ToolBar2'
Images = ilCXOQL
List = True
ShowCaptions = True
TabOrder = 1
object ToolButton5: TToolButton
Left = 1
Top = 2
Action = aNewOQL
end
object ToolButton6: TToolButton
Left = 80
Top = 2
Action = aDeleteOQL
end
end
end
object pnlRight: TPanel
Left = 2
27
Height = 4
97
Left = 2
78
Height = 4
89
Top = 0
Width = 8
55
Width = 8
02
Align = alClient
BevelOuter = bvNone
ClientHeight = 4
97
ClientWidth = 8
55
ClientHeight = 4
89
ClientWidth = 8
02
TabOrder = 1
object pnlOQLExplorer: TPanel
Left = 0
Height = 4
24
Height = 4
16
Top = 73
Width = 8
55
Width = 8
02
Align = alClient
BevelOuter = bvNone
ParentBackground = False
...
...
@@ -11707,16 +11711,16 @@ object OQLExplorerV2: TOQLExplorerV2
Left = 0
Height = 73
Top = 0
Width = 8
55
Width = 8
02
Align = alTop
BevelOuter = bvNone
ClientHeight = 73
ClientWidth = 8
55
ClientWidth = 8
02
ParentBackground = False
TabOrder = 0
object labelName: TLabel
Left = 58
Height = 1
3
Height = 1
4
Top = 13
Width = 31
Caption = 'Name:'
...
...
@@ -11724,7 +11728,7 @@ object OQLExplorerV2: TOQLExplorerV2
end
object labelDescription: TLabel
Left = 32
Height = 1
3
Height = 1
4
Top = 43
Width = 57
Caption = 'Description:'
...
...
@@ -11732,14 +11736,14 @@ object OQLExplorerV2: TOQLExplorerV2
end
object edtName: TEdit
Left = 97
Height =
2
1
Height =
3
1
Top = 10
Width = 384
TabOrder = 0
end
object edtDescription: TEdit
Left = 97
Height =
2
1
Height =
3
1
Top = 40
Width = 384
TabOrder = 1
...
...
@@ -11750,8 +11754,8 @@ object OQLExplorerV2: TOQLExplorerV2
end
object tsPASunit: TTabSheet
Caption = 'Unit'
ClientHeight = 4
97
ClientWidth = 108
2
ClientHeight = 4
89
ClientWidth = 108
0
ImageIndex = 1
object pnlPASUnit: TPanel
Left = 0
...
...
@@ -11776,6 +11780,39 @@ object OQLExplorerV2: TOQLExplorerV2
end
end
end
object ToolBar1: TToolBar
Left = 0
Height = 35
Top = 0
Width = 1090
ButtonHeight = 24
ButtonWidth = 24
Caption = 'ToolBar1'
Images = ilCXOQL
List = True
ShowCaptions = True
TabOrder = 1
object ToolButton1: TToolButton
Left = 1
Top = 2
Action = aNewFile
end
object ToolButton2: TToolButton
Left = 56
Top = 2
Action = aLoadFile
end
object ToolButton3: TToolButton
Left = 116
Top = 2
Action = aSaveFile
end
object ToolButton4: TToolButton
Left = 174
Top = 2
Action = aExportPas
end
end
object abExportPAS: TAction
Caption = 'abExportPAS'
Visible = False
...
...
@@ -12588,8 +12625,8 @@ object OQLExplorerV2: TOQLExplorerV2
}
end
object ilOQLState: TImageList
left =
16
top =
472
left =
861
top =
5
Bitmap = {
4C6903000000100000001000000000000000000000000071ADFF0071ADFF0071
ADFF0071ADFF0071ADFF0071ADFF000000000000000000000000000000000000
...
...
@@ -12702,4 +12739,38 @@ object OQLExplorerV2: TOQLExplorerV2
Filter = 'pas|*.pas'
left = 616
end
object ActionList1: TActionList
left = 926
top = 6
object aNewOQL: TAction
Caption = '&New OQL'
ImageIndex = 5
OnExecute = aNewOQLExecute
end
object aDeleteOQL: TAction
Caption = '&Delete OQL'
ImageIndex = 9
OnExecute = aDeleteOQLExecute
end
object aNewFile: TAction
Caption = 'Ne&w'
ImageIndex = 10
OnExecute = aNewFileExecute
end
object aLoadFile: TAction
Caption = '&Open'
ImageIndex = 3
OnExecute = aLoadFileExecute
end
object aSaveFile: TAction
Caption = '&Save'
ImageIndex = 7
OnExecute = aSaveFileExecute
end
object aExportPas: TAction
Caption = '&Export'
ImageIndex = 8
OnExecute = aExportPASExecute
end
end
end
EvoUMLPlugin/src/ituOQLExplorerV2.pas
View file @
d36b4459
...
...
@@ -21,16 +21,23 @@ type
{ TOQLExplorerV2 }
TOQLExplorerV2
=
class
(
TForm
)
ilCXOQL
:
TImageList
;
pnlActionBar
:
TPanel
;
abExportPAS
:
TAction
;
abCXOQL
:
TAction
;
aNewOQL
:
TAction
;
aDeleteOQL
:
TAction
;
aExportPas
:
TAction
;
aSaveFile
:
TAction
;
aLoadFile
:
TAction
;
aExportPAS
:
TAction
;
aNewFile
:
TAction
;
aDeleteOQL
:
TAction
;
aNewOQL
:
TAction
;
ActionList1
:
TActionList
;
ilCXOQL
:
TImageList
;
pcCXOQL
:
TPageControl
;
ToolBar1
:
TToolBar
;
ToolBar2
:
TToolBar
;
ToolButton1
:
TToolButton
;
ToolButton2
:
TToolButton
;
ToolButton3
:
TToolButton
;
ToolButton4
:
TToolButton
;
ToolButton5
:
TToolButton
;
ToolButton6
:
TToolButton
;
tsCXOQL
:
TTabSheet
;
tsPASunit
:
TTabSheet
;
ilOQLState
:
TImageList
;
...
...
@@ -51,10 +58,7 @@ type
SaveDialog1
:
TSaveDialog
;
SaveUnit
:
TSaveDialog
;
memUnit
:
TMemo
;
pnlOQLButtons
:
TPanel
;
pnlList
:
TPanel
;
acttbOQL
:
TAction
;
aNewFile
:
TAction
;
procedure
FormClose
(
Sender
:
TObject
;
var
Action
:
TCloseAction
);
procedure
aNewOQLExecute
(
Sender
:
TObject
);
procedure
FormCreate
(
Sender
:
TObject
);
...
...
@@ -66,7 +70,6 @@ type
procedure
FormCloseQuery
(
Sender
:
TObject
;
var
CanClose
:
Boolean
);
procedure
FormResize
(
Sender
:
TObject
);
procedure
lvOQLListChange
(
Sender
:
TObject
;
Item
:
TListItem
;
Change
:
TItemChange
);
procedure
lvOQLListChanging
(
Sender
:
TObject
;
Item
:
TListItem
;
Change
:
TItemChange
;
var
AllowChange
:
Boolean
);
procedure
aNewFileExecute
(
Sender
:
TObject
);
procedure
splVerticalCanResize
(
Sender
:
TObject
;
var
NewSize
:
Integer
;
var
Accept
:
Boolean
);
...
...
@@ -78,6 +81,8 @@ type
fFlagFormClosing
:
Boolean
;
// Impede que as OQLs sejam inutilmente verificados ao fechar o form
fExplorer
:
TExplorerV2
;
fOQLList
:
utOQLFile
;
fLastItem
:
TListItem
;
function
GerarUnitOQL
(
piXMLFileName
:
String
):
string
;
procedure
InterfaceToSelectedOQL
;
function
GetQueryType
(
piExplorer
:
TExplorerV2
)
:
Integer
;
function
ValidaQuery
(
piQuery
:
string
;
piOQLType
:
integer
):
string
;
...
...
@@ -98,7 +103,7 @@ var
implementation
uses
acuObject
,
acuOQL
,
IntegracaoDelphiSUML
;
uses
acuObject
,
acuOQL
,
acuOQLtoSQLTranslator
,
IntegracaoDelphiSUML
,
utuMessage
;
{$R *.dfm}
...
...
@@ -113,6 +118,7 @@ begin
lvOQLList
.
Selected
.
Delete
;
lOQL
.
Delete
;
fLastItem
:=
Nil
;
if
lvOQLList
.
Items
.
Count
>
0
then
if
li
-
1
>=
0
then
lvOQLList
.
Selected
:=
lvOQLList
.
Items
[
li
-
1
]
...
...
@@ -126,14 +132,14 @@ procedure TOQLExplorerV2.aExportPASExecute(Sender: TObject);
var
lFileName
:
string
;
begin
if
fOQLList
.
FileName
=
''
then
ShowMessage
(
'
Need to save file before generation
.'
)
ShowMessage
(
'
You need to save before exporting
.'
)
else
begin
InterfaceToSelectedOQL
;
fOQLList
.
Save
;
Screen
.
Cursor
:=
crHourGlass
;
try
memUnit
.
Lines
.
Text
:=
fExplorer
.
Util
.
GerarUnitOQL
(
fOQLList
.
FileName
);
memUnit
.
Lines
.
Text
:=
GerarUnitOQL
(
fOQLList
.
FileName
);
finally
Screen
.
Cursor
:=
crDefault
;
end
;
...
...
@@ -148,19 +154,298 @@ begin
end
;
end
;
function
TOQLExplorerV2
.
GerarUnitOQL
(
piXMLFileName
:
String
):
string
;
procedure
AddText
(
piStringStream
:
TStringStream
;
piIndent
:
integer
=
0
;
piText
:
string
=
''
);
begin
piText
:=
StringOfChar
(
' '
,
piIndent
)
+
piText
;
piStringStream
.
WriteString
(
concat
(
piText
,#
13
#
10
));
end
;
var
lUnit
:
TStringStream
;
lFieldOQLFile
,
lFieldOQL
:
utField
;
lAux
:
TStringList
;
lOQLName
,
lOQLQuery
:
string
;
lEnum
,
lEnumParams
:
acEnumerator
;
lOQLParam
:
acOQLParam
;
lOQLtoSQLTranslator
:
acOQLtoSQLTranslator
;
lQueryParams
:
acQueryParams
;
lFileName
:
string
;
lOQLType
:
integer
;
lSQL
:
string
;
begin
if
not
FileExists
(
piXMLFileName
)
then
raise
Exception
.
Create
(
'File "'
+
piXMLFileName
+
'" does not exist'
);
lUnit
:=
TStringStream
.
Create
(
''
);
try
lFieldOQLFile
:=
utField
.
Create
;
try
lAux
:=
TStringList
.
Create
;
try
lAux
.
LoadFromFile
(
piXMLFileName
);
lFieldOQLFile
.
LoadFieldFromXMLString
(
lAux
.
Text
);
finally
lAux
.
free
;
end
;
lFileName
:=
ExtractFileName
(
piXMLFileName
);
lFileName
:=
LeftStr
(
lFileName
,
pos
(
'.'
,
lFileName
)
-
1
);
AddText
(
lUnit
,
0
,
'unit utu'
+
lFileName
+
';'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'interface'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'uses acuOQL, acuFramework;'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'type'
);
AddText
(
lUnit
);
lEnum
:=
lFieldOQLFile
.
GetFieldsEnumerator
;
try
//OQL Interfaces
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
if
not
lFieldOQL
.
HasAttribute
(
'name'
)
then
raise
Exception
.
Create
(
'Attribute "name" not found for OQL. Not a valid XML OQL file.'
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
if
not
lFieldOQL
.
HasField
(
'query'
)
then
raise
Exception
.
Create
(
'Field "query" not found for OQL. Not a valid XML OQL file.'
);
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
//Default cOQLQuery
lOQLType
:=
cOQLQuery
;
if
lFieldOQL
.
HasAttribute
(
'oqltype'
)
then
lOQLType
:=
lFieldOQL
.
AttributeByName
(
'oqltype'
).
AsInteger
;
case
lOQLType
of
cDataSetOQLDataSet
:
AddText
(
lUnit
,
2
,
'I'
+
lOQLName
+
' = interface(IDataSetOQLQuery)'
);
else
AddText
(
lUnit
,
2
,
'I'
+
lOQLName
+
' = interface(IOQLQuery)'
);
end
;
lQueryParams
:=
acQueryParams
.
Create
;
try
lOQLtoSQLTranslator
:=
acOQLtoSQLTranslator
.
Create
(
fExplorer
.
Util
.
MetaModelPersistenceMap
);
try
case
lOQLType
of
cDataSetOQLDataSet
:
begin
lSQL
:=
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
lOQLQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkDataSet
,
lQueryParams
);
end
;
else
begin
lSQL
:=
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
lOQLQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkObject
,
lQueryParams
);
end
;
end
;
finally
lOQLtoSQLTranslator
.
Free
;
end
;
lEnumParams
:=
lQueryParams
.
GetEnumerator
;
try
while
not
lEnumParams
.
EOL
do
begin
lOQLParam
:=
acOQLParam
(
lEnumParams
.
Current
);
AddText
(
lUnit
,
4
,
'function Param_'
+
lOQLParam
.
Name
+
': '
+
lOQLParam
.
ClassName
+
';'
);
lEnumParams
.
MoveNext
;
end
;
finally
lEnumParams
.
free
;
end
;
AddText
(
lUnit
,
2
,
'end;'
);
AddText
(
lUnit
);
finally
lQueryParams
.
Free
;
end
;
lEnum
.
MoveNext
;
end
;
//Factory Class Interface
AddText
(
lUnit
,
2
,
'ut'
+
lFileName
+
' = class'
);
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
AddText
(
lUnit
,
4
,
'class function '
+
lOQLName
+
'(piSessao: acPersistenceSession): '
+
'I'
+
lOQLName
+
';'
);
lEnum
.
MoveNext
;
end
;
AddText
(
lUnit
,
2
,
'end;'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'implementation'
);
AddText
(
lUnit
);
AddText
(
lUnit
,
0
,
'type'
);
AddText
(
lUnit
);
//OQL Types
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
//Default cOQLQuery
lOQLType
:=
cOQLQuery
;
if
lFieldOQL
.
HasAttribute
(
'oqltype'
)
then
lOQLType
:=
lFieldOQL
.
AttributeByName
(
'oqltype'
).
AsInteger
;
case
lOQLType
of
cDataSetOQLDataSet
:
AddText
(
lUnit
,
2
,
'T'
+
lOQLName
+
' = class(acDataSetOQLQuery, '
+
'I'
+
lOQLName
+
')'
);
else
AddText
(
lUnit
,
2
,
'T'
+
lOQLName
+
' = class(acOQLQuery, '
+
'I'
+
lOQLName
+
')'
);
end
;
lQueryParams
:=
acQueryParams
.
Create
;
try
lOQLtoSQLTranslator
:=
acOQLtoSQLTranslator
.
Create
(
fExplorer
.
Util
.
MetaModelPersistenceMap
);
try
case
lOQLType
of
cDataSetOQLDataSet
:
begin
lSQL
:=
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
lOQLQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkDataSet
,
lQueryParams
);
end
;
else
begin
lSQL
:=
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
lOQLQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkObject
,
lQueryParams
);
end
;
end
;
finally
lOQLtoSQLTranslator
.
Free
;
end
;
lEnumParams
:=
lQueryParams
.
GetEnumerator
;
try
while
not
lEnumParams
.
EOL
do
begin
lOQLParam
:=
acOQLParam
(
lEnumParams
.
Current
);
AddText
(
lUnit
,
4
,
'function Param_'
+
lOQLParam
.
Name
+
': '
+
lOQLParam
.
ClassName
+
';'
);
lEnumParams
.
MoveNext
;
end
;
finally
lEnumParams
.
free
;
end
;
AddText
(
lUnit
,
2
,
'end;'
);
AddText
(
lUnit
);
finally
lQueryParams
.
Free
;
end
;
lEnum
.
MoveNext
;
end
;
//OQL Types Implementation
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
//Default cOQLQuery
lOQLType
:=
cOQLQuery
;
if
lFieldOQL
.
HasAttribute
(
'oqltype'
)
then
lOQLType
:=
lFieldOQL
.
AttributeByName
(
'oqltype'
).
AsInteger
;
AddText
(
lUnit
,
0
,
'{ T'
+
lOQLName
+
' }'
);
AddText
(
lUnit
);
lQueryParams
:=
acQueryParams
.
Create
;
try
lOQLtoSQLTranslator
:=
acOQLtoSQLTranslator
.
Create
(
fExplorer
.
Util
.
MetaModelPersistenceMap
);
try
case
lOQLType
of
cDataSetOQLDataSet
:
begin
lSQL
:=
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
lOQLQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkDataSet
,
lQueryParams
);
end
;
else
begin
lSQL
:=
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
lOQLQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkObject
,
lQueryParams
);
end
;
end
;
finally
lOQLtoSQLTranslator
.
Free
;
end
;
lEnumParams
:=
lQueryParams
.
GetEnumerator
;
try
while
not
lEnumParams
.
EOL
do
begin
lOQLParam
:=
acOQLParam
(
lEnumParams
.
Current
);
AddText
(
lUnit
,
0
,
'function T'
+
lOQLName
+
'.Param_'
+
lOQLParam
.
Name
+
': '
+
lOQLParam
.
ClassName
+
';'
);
AddText
(
lUnit
,
0
,
'begin'
);
AddText
(
lUnit
,
2
,
'result := '
+
lOQLParam
.
ClassName
+
'(Self.ParamByName('
+
QuotedStr
(
lOQLParam
.
Name
)
+
'));'
);
AddText
(
lUnit
,
0
,
'end;'
);
AddText
(
lUnit
);
lEnumParams
.
MoveNext
;
end
;
finally
lEnumParams
.
free
;
end
;
finally
lQueryParams
.
Free
;
end
;
lEnum
.
MoveNext
;
end
;
//Factory Class Implementation
AddText
(
lUnit
,
0
,
'{ utOQLs }'
);
AddText
(
lUnit
);
lEnum
.
MoveFirst
;
while
not
lEnum
.
EOL
do
begin
lFieldOQL
:=
utField
(
lEnum
.
Current
);
lOQLName
:=
lFieldOQL
.
AttributeByName
(
'name'
).
AsString
;
lOQLQuery
:=
lFieldOQL
.
FieldByName
(
'query'
).
AsString
;
AddText
(
lUnit
,
0
,
'class function ut'
+
lFileName
+
'.'
+
lOQLName
+
'(piSessao: acPersistenceSession): I'
+
lOQLName
+
';'
);
AddText
(
lUnit
,
0
,
'begin'
);
AddText
(
lUnit
,
2
,
'result := T'
+
lOQLName
+
'.Create(pisessao,'
);
lOQLQuery
:=
StringReplace
(
lOQLQuery
,
''''
,
''''''
,
[
rfReplaceAll
]);
lOQLQuery
:=
StringReplace
(
lOQLQuery
,
#
13
#
10
,
''' + #13#10 +'
+
#
13
#
10
+
''''
,
[
rfReplaceAll
]);
AddText
(
lUnit
,
0
,
''''
+
lOQLQuery
+
''');'
);
AddText
(
lUnit
,
0
,
'end;'
);
AddText
(
lUnit
);
lEnum
.
MoveNext
;
end
;
finally
lEnum
.
free
;
end
;
AddText
(
lUnit
,
0
,
'end.'
);
result
:=
lUnit
.
DataString
;
finally
lFieldOQLFile
.
free
;
end
;
finally
lUnit
.
free
;
end
;
end
;
procedure
TOQLExplorerV2
.
aLoadFileExecute
(
Sender
:
TObject
);
var
lM
:
integer
;
lCancel
:
Boolean
;
begin
lCancel
:=
False
;
if
(
lvOQLList
.
Items
.
Count
>
1
)
or
(
edtName
.
Caption
<>
'_NEW_OQL_1'
)
then
begin
lM
:=
application
.
MessageBox
(
'Save before open another file?'
,
'Attention'
,
MB_ICONQUESTION
+
MB_YESNO
);
case
lM
of
IDYES
:
aSaveFileExecute
(
Sender
);
IDCANCEL
:
lCancel
:=
True
;
end
;
end
;
if
not
(
lCancel
)
then
begin
...
...
@@ -182,7 +467,7 @@ begin
end
;
end
;
finally
Caption
:=
fOQLList
.
FileName
;
Caption
:=
'Curió OQL Studio - '
+
fOQLList
.
FileName
;
UpdateOQLList
;
end
;
end
;
...
...
@@ -256,7 +541,7 @@ begin
lvOQLList
.
SortType
:=
stText
;
lvOQLList
.
SortType
:=
stNone
;
fOQLList
.
Save
(
lFileName
);
Caption
:=
lFileName
;
Caption
:=
'Curió OQL Studio - '
+
lFileName
;
Application
.
MessageBox
(
'File saved.'
,
''
,
MB_ICONINFORMATION
);
except
on
E
:
Exception
do
...
...
@@ -296,11 +581,14 @@ end;
procedure
TOQLExplorerV2
.
FormCloseQuery
(
Sender
:
TObject
;
var
CanClose
:
Boolean
);
var
lM
:
integer
;
begin
if
(
lvOQLList
.
Items
.
Count
>
1
)
or
(
edtName
.
Caption
<>
'_NEW_OQL_1'
)
then
begin
lM
:=
application
.
MessageBox
(
'Save before close?'
,
'Attention'
,
MB_ICONQUESTION
+
MB_YESNO
);
case
lM
of
IDYES
:
aSaveFileExecute
(
sender
);
IDCANCEL
:
CanClose
:=
false
;
end
;
end
;
end
;
procedure
TOQLExplorerV2
.
FormCreate
(
Sender
:
TObject
);
...
...
@@ -309,7 +597,7 @@ begin
lFileName
:=
''
;
fOQLList
:=
utOQLFile
.
create
(
lFileName
);
UpdateOQLList
;
Caption
:=
'
New...
'
;
Caption
:=
'
Curió OQL Studio
'
;
end
;
procedure
TOQLExplorerV2
.
FormResize
(
Sender
:
TObject
);
...
...
@@ -337,9 +625,9 @@ procedure TOQLExplorerV2.InterfaceToSelectedOQL;
var
lOQL
:
utOQL
;
lErro
:
string
;
begin
if
Assigned
(
lvOQLList
.
Selected
)
and
Assigned
(
fExplorer
.
SynEditOQL
)
then
if
Assigned
(
fLastItem
)
and
Assigned
(
fExplorer
.
SynEditOQL
)
then
begin
lOQL
:=
utOQL
(
lvOQLList
.
Selected
.
Data
);
lOQL
:=
utOQL
(
fLastItem
.
Data
);
lOQL
.
ID
:=
edtName
.
Text
;
lOQL
.
Description
:=
edtDescription
.
Text
;
lOQL
.
Query
:=
fExplorer
.
SynEditOQL
.
Text
;
...
...
@@ -352,42 +640,40 @@ begin
if
lErro
=
''
then
begin
if
lOQL
.
OQLType
=
1
then
lvOQLList
.
Selected
.
ImageIndex
:=
1
else
lvOQLList
.
Selected
.
ImageIndex
:=
0
;
then
fLastItem
.
ImageIndex
:=
1
else
fLastItem
.
ImageIndex
:=
0
;
end
else
lvOQLList
.
Selected
.
ImageIndex
:=
2
;
lvOQLList
.
Selected
.
Caption
:=
edtName
.
Text
;
lvOQLList
.
Selected
.
SubItems
[
0
]
:=
lErro
;
fLastItem
.
ImageIndex
:=
2
;
fLastItem
.
Caption
:=
edtName
.
Text
;
fLastItem
.
SubItems
[
0
]
:=
lErro
;
end
;
end
;
procedure
TOQLExplorerV2
.
lvOQLListChange
(
Sender
:
TObject
;
Item
:
TListItem
;
Change
:
TItemChange
);
begin
if
assigned
(
fLastItem
)
and
(
fLastItem
<>
Item
)
then
InterfaceToSelectedOQL
;
SelectedOQLToInterface
;
end
;
procedure
TOQLExplorerV2
.
lvOQLListChanging
(
Sender
:
TObject
;
Item
:
TListItem
;
Change
:
TItemChange
;
var
AllowChange
:
Boolean
);
begin
InterfaceToSelectedOQL
;
end
;
procedure
TOQLExplorerV2
.
SelectedOQLToInterface
;
var
lOQL
:
utOQL
;
begin
edtName
.
Text
:=
''
;
edtDescription
.
Text
:=
''
;
fExplorer
.
SynEditOQL
.
Text
:=
''
;
if
Assigned
(
lvOQLList
.
Selected
)
and
Assigned
(
fExplorer
.
SynEditOQL
)
then
begin
f
Explorer
.
SynEditOQL
.
Text
:=
''
;
f
LastItem
:=
lvOQLList
.
Selected
;
lOQL
:=
utOQL
(
lvOQLList
.
Selected
.
Data
);
edtName
.
Text
:=
lOQL
.
ID
;
edtDescription
.
Text
:=
lOQL
.
Description
;
fExplorer
.
SynEditOQL
.
Text
:=
lOQL
.
Query
;
memError
.
Text
:=
lvOQLList
.
Selected
.
SubItems
[
0
];
SetQueryType
(
lOQL
.
OQLType
);
end
;
lvOQLList
.
Column
[
0
].
Caption
:=
'OQL Name ('
+
IntToStr
(
fOQLList
.
Count
)
+
')'
;
end
else
fLastItem
:=
Nil
;
lvOQLList
.
Column
[
0
].
Caption
:=
'OQL''s ('
+
IntToStr
(
fOQLList
.
Count
)
+
')'
;
end
;
procedure
TOQLExplorerV2
.
SetQueryType
(
piType
:
integer
);
...
...
@@ -446,7 +732,7 @@ begin
end
;
function
TOQLExplorerV2
.
ValidaQuery
(
piQuery
:
string
;
piOQLType
:
integer
):
string
;
var
l
Query
:
acAbstractOQLQuery
;
var
l
OQLtoSQLTranslator
:
acOQLtoSQLTranslator
;
begin
result
:=
''
;
if
not
fFlagFormClosing
then
...
...
@@ -454,21 +740,27 @@ begin
try
if
Assigned
(
fExplorer
)
then
begin
// if Assigned(fExplorer.Session) then
// begin
// if piOQLType = 1 then
// lQuery := acDataSetOQLQuery.Create(fExplorer.Session, piQuery)
// else
// lQuery := acOQLQuery.Create(fExplorer.Session, piQuery);
// lQuery.Free;
// end;
lOQLtoSQLTranslator
:=
acOQLtoSQLTranslator
.
Create
(
fExplorer
.
Util
.
MetaModelPersistenceMap
);
try
case
piOQLType
of
cDataSetOQLDataSet
:
begin
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
piQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkDataSet
);
end
;
else
begin
lOQLtoSQLTranslator
.
TranslateOQLtoSQL
(
piQuery
,
fExplorer
.
SQLDialect
,
fExplorer
.
Schema
,
acQueryResultKind
.
qrkObject
);
end
;
end
;
finally
lOQLtoSQLTranslator
.
Free
;
end
;
end
;
except
on
e
:
exception
do
begin
Result
:=
e
.
Message
;
end
;
end
;
end
;
end
;
...
...
EvoUMLPlugin/src/ituServiceParameters.dfm
View file @
d36b4459
object itServiceParameters: TitServiceParameters
Left =
0
Height = 2
76
Top =
0
Width = 3
06
Left =
778
Height = 2
89
Top =
453
Width = 3
14
BorderStyle = bsDialog
Caption = 'Propriedades do Serviço'
ClientHeight = 276
ClientWidth = 306
Color = clBtnFace
ClientHeight = 289
ClientWidth = 314
ParentFont = True
Position = poDesktopCenter
Position = poScreenCenter
LCLVersion = '2.0.0.4'
object Panel2: TPanel
Left = 0
Height = 2
37
Height = 2
40
Top = 0
Width = 3
06
Width = 3
14
Align = alClient
ClientHeight = 2
37
ClientWidth = 3
06
ClientHeight = 2
40
ClientWidth = 3
14
TabOrder = 1
object GroupBox1: TGroupBox
Left = 6
Height = 77
Top = 3
Width = 296
ClientHeight = 7
0
ClientWidth = 2
88
ClientHeight = 7
5
ClientWidth = 2
94
TabOrder = 0
object Label2: TLabel
Left = 5
Height = 1
6
Height = 1
9
Top = 14
Width = 1
17
Width = 1
22
Caption = 'Nome do Servidor:'
ParentColor = False
end
object Label1: TLabel
Left = 11
Height = 1
6
Height = 1
9
Top = 42
Width = 11
1
Width = 11
6
Caption = 'Número da Porta:'
ParentColor = False
end
object edtServerName: TEdit
Left = 133
Height = 2
2
Height = 2
9
Top = 8
Width = 155
TabOrder = 0
end
object edtPortNumber: TEdit
Left = 133
Height = 2
2
Height = 2
9
Top = 36
Width = 155
TabOrder = 1
...
...
@@ -63,20 +63,20 @@ object itServiceParameters: TitServiceParameters
Height = 48
Top = 88
Width = 296
ClientHeight = 4
1
ClientWidth = 2
88
ClientHeight = 4
6
ClientWidth = 2
94
TabOrder = 1
object Label3: TLabel
Left = 0
Height = 1
6
Height = 1
9
Top = 12
Width = 12
2
Width = 12
6
Caption = 'Código do Sistema:'
ParentColor = False
end
object edtSystemCode: TEdit
Left = 133
Height = 2
2
Height = 2
9
Top = 8
Width = 155
TabOrder = 0
...
...
@@ -87,35 +87,35 @@ object itServiceParameters: TitServiceParameters
Height = 80
Top = 144
Width = 296
ClientHeight = 7
3
ClientWidth = 2
88
ClientHeight = 7
8
ClientWidth = 2
94
TabOrder = 2
object Label5: TLabel
Left = 9
Height = 1
6
Height = 1
9
Top = 12
Width = 11
3
Width = 11
7
Caption = 'Nome do Usuário:'
ParentColor = False
end
object Label4: TLabel
Left = 80
Height = 1
6
Height = 1
9
Top = 46
Width = 4
2
Width = 4
5
Caption = 'Senha:'
ParentColor = False
end
object edtUserName: TEdit
Left = 133
Height = 2
2
Height = 2
9
Top = 6
Width = 155
TabOrder = 0
end
object edtPassword: TEdit
Left = 133
Height = 2
2
Height = 2
9
Top = 40
Width = 155
EchoMode = emPassword
...
...
@@ -126,18 +126,18 @@ object itServiceParameters: TitServiceParameters
end
object Panel1: TPanel
Left = 0
Height =
3
9
Top = 2
37
Width = 3
06
Height =
4
9
Top = 2
40
Width = 3
14
Align = alBottom
ClientHeight =
3
9
ClientWidth = 3
06
ClientHeight =
4
9
ClientWidth = 3
14
TabOrder = 0
object BitBtn1: TBitBtn
Left =
141
Height =
2
5
Left =
96
Height =
3
5
Top = 6
Width =
75
Width =
99
Anchors = [akTop, akLeft, akBottom]
Caption = 'Ok'
Kind = bkOK
...
...
@@ -146,10 +146,10 @@ object itServiceParameters: TitServiceParameters
TabOrder = 0
end
object BitBtn2: TBitBtn
Left = 2
29
Height =
2
5
Left = 2
03
Height =
3
5
Top = 6
Width =
75
Width =
97
Anchors = [akTop, akLeft, akBottom]
Caption = 'Cancel'
Kind = bkCancel
...
...
EvoUMLPlugin/src/ituServiceParameters.pas
View file @
d36b4459
...
...
@@ -4,7 +4,7 @@ interface
uses
LCLType
,
Messages
,
SysUtils
,
Variants
,
Classes
,
Graphics
,
Controls
,
Forms
,
Dialogs
,
StdCtrls
,
Buttons
,
ExtCtrls
;
Dialogs
,
StdCtrls
,
Buttons
,
ExtCtrls
,
cxuSession
;
type
TitServiceParameters
=
class
(
TForm
)
...
...
@@ -27,6 +27,7 @@ type
Label4
:
TLabel
;
procedure
BitBtn1Click
(
Sender
:
TObject
);
private
fSession
:
cxSession
;
function
GetPassword
:
string
;
function
GetPortNumber
:
integer
;
function
GetServerName
:
string
;
...
...
@@ -40,6 +41,7 @@ type
{ Private declarations }
public
{ Public declarations }
property
Session
:
cxSession
read
fSession
write
fSession
;
property
ServerName
:
string
read
GetServerName
write
SetServerName
;
property
PortNumber
:
integer
read
GetPortNumber
write
SetPortNumber
;
property
SystemCode
:
integer
read
GetSystemCode
write
SetSystemCode
;
...
...
@@ -55,6 +57,7 @@ implementation
{ TServiceParameters }
procedure
TitServiceParameters
.
BitBtn1Click
(
Sender
:
TObject
);
var
lConnectioString
:
String
;
begin
if
edtServerName
.
Text
=
''
then
begin
...
...
@@ -79,7 +82,7 @@ begin
end
;
try
strtoi
nt
(
edtPortNumber
.
Text
);
StrToI
nt
(
edtPortNumber
.
Text
);
except
Application
.
MessageBox
(
'Porta informada invlida.'
,
'Ateno'
,
MB_ICONEXCLAMATION
);
edtPortNumber
.
SetFocus
;
...
...
@@ -88,13 +91,29 @@ begin
end
;
try
strtoi
nt
(
edtSystemCode
.
Text
);
StrToI
nt
(
edtSystemCode
.
Text
);
except
Application
.
MessageBox
(
'Cdigo do sistema informado invlido.'
,
'Ateno'
,
MB_ICONEXCLAMATION
);
edtSystemCode
.
SetFocus
;
edtSystemCode
.
SelectAll
;
modalresult
:=
mrnone
;
end
;
try
lConnectioString
:=
format
(
'ServerName=%s;PortNumber=%d;SystemCode=%d;UserName=%s;Password=%s;'
,
[
edtServerName
.
Caption
,
StrToInt
(
edtPortNumber
.
Caption
),
StrToInt
(
edtSystemCode
.
Caption
),
edtUserName
.
Caption
,
edtPassword
.
Caption
]);
fSession
:=
cxSession
.
Create
(
lConnectioString
);
except
on
e
:
Exception
do
begin
Application
.
MessageBox
(
PCHAR
(
e
.
Message
),
'Ateno'
,
MB_ICONEXCLAMATION
);
modalresult
:=
mrnone
;
end
;
end
;
end
;
function
TitServiceParameters
.
GetPassword
:
string
;
...
...
EvoUMLPlugin/src/uCadastroCasoDeUso.dfm
View file @
d36b4459
object CadastroCasoDeUso: TCadastroCasoDeUso
Left =
0
Height =
395
Top =
0
Width = 78
1
Left =
902
Height =
456
Top =
226
Width = 78
2
BorderStyle = bsDialog
Caption = 'Cadastro de caso de uso'
ClientHeight = 395
ClientWidth = 781
Color = clBtnFace
ParentFont = True
Position = poDesktopCenter
Caption = 'Cadastro de Caso de Uso'
ClientHeight = 456
ClientWidth = 782
Position = poScreenCenter
LCLVersion = '2.0.0.4'
object pnPrincipal: TPanel
Left = 8
Height = 263
Top = 9
Width = 768
Left = 0
Height = 316
Top = 0
Width = 782
Align = alTop
BevelOuter = bvLowered
ClientHeight = 263
ClientWidth = 768
Color = 15658734
ClientHeight = 316
ClientWidth = 782
ParentColor = False
TabOrder = 0
object lblNome: TLabel
Left = 8
Height = 1
3
Height = 1
4
Top = 88
Width = 3
2
Width = 3
1
Caption = 'Nome'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -36,9 +35,9 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object lblCodigo: TLabel
Left = 8
Height = 1
3
Height = 1
4
Top = 6
Width = 3
8
Width = 3
9
Caption = 'Código'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -49,9 +48,9 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object lblDescricao: TLabel
Left = 8
Height = 1
3
Top = 1
31
Width = 5
4
Height = 1
4
Top = 1
40
Width = 5
5
Caption = 'Descrição'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -62,9 +61,9 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object lblEntidade: TLabel
Left = 8
Height = 1
3
Top = 2
22
Width =
49
Height = 1
4
Top = 2
51
Width =
50
Caption = 'Entidade'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -75,9 +74,9 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object lblCategoria: TLabel
Left = 8
Height = 1
3
Top = 1
76
Width = 5
3
Height = 1
4
Top = 1
93
Width = 5
6
Caption = 'Categoria'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -88,18 +87,18 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object lblValorCodigo: TLabel
Left = 8
Height = 1
6
Height = 1
9
Top = 24
Width = 6
3
Width = 6
1
Caption = '<código>'
Layout = tlCenter
ParentColor = False
end
object Label1: TLabel
Left = 304
Height = 1
5
Height = 1
4
Top = 6
Width =
56
Width =
65
Caption = 'Operações'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -109,10 +108,10 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
ParentFont = False
end
object Label2: TLabel
Left =
437
Height = 1
5
Left =
538
Height = 1
4
Top = 6
Width =
48
Width =
56
Caption = 'Sistemas'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -123,15 +122,15 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object edtNome: TEdit
Left = 8
Height =
22
Height =
31
Top = 103
Width = 289
TabOrder = 0
end
object cbxEntidade: TComboBox
Left = 8
Height =
20
Top = 2
37
Height =
37
Top = 2
70
Width = 289
AutoDropDown = True
ItemHeight = 0
...
...
@@ -141,8 +140,8 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object cbxCategoria: TComboBox
Left = 8
Height =
20
Top =
193
Height =
37
Top =
212
Width = 289
AutoDropDown = True
ItemHeight = 0
...
...
@@ -152,7 +151,7 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object ltvSistema: TListView
Left = 536
Height = 2
33
Height = 2
80
Top = 24
Width = 232
AutoWidthLastColumn = True
...
...
@@ -160,14 +159,15 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
Columns = <
item
Caption = 'Sistemas'
Width = 2
26
Width = 2
30
end>
ScrollBars = ssAutoBoth
SortType = stText
TabOrder = 5
end
object ltvOperacao: TListView
Left = 304
Height = 2
33
Height = 2
80
Top = 24
Width = 224
AutoWidthLastColumn = True
...
...
@@ -175,31 +175,32 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
Columns = <
item
Caption = 'Operações'
Width = 2
18
Width = 2
22
end>
ScrollBars = ssAutoBoth
SortType = stText
TabOrder = 4
end
object edtDescricao: TEdit
Left = 8
Height =
22
Top = 1
46
Height =
31
Top = 1
55
Width = 289
TabOrder = 1
end
object GroupBox1: TGroupBox
Left = 2
09
Left = 2
26
Height = 90
Top = 6
Width =
88
Width =
71
Caption = 'Ícone'
ClientHeight =
68
ClientWidth =
80
ClientHeight =
70
ClientWidth =
69
TabOrder = 6
object Label5: TLabel
Left =
20
Left =
17
Height = 28
Top = 2
4
Top = 2
2
Width = 37
Alignment = taCenter
AutoSize = False
...
...
@@ -216,28 +217,29 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
end
object imgIcone: TImage
Cursor = crHandPoint
Left =
8
Height =
55
Top =
8
Width = 6
3
Left =
5
Height =
60
Top =
5
Width = 6
0
Center = True
OnClick = imgIconeClick
end
end
end
object Panel1: TPanel
Left = 220
Height = 56
Top = 288
Width = 556
ClientHeight = 56
ClientWidth = 556
TabOrder = 2
Left = 0
Height = 74
Top = 316
Width = 782
Align = alTop
ClientHeight = 74
ClientWidth = 782
TabOrder = 1
object Label3: TLabel
Left =
8
Height = 1
3
Top =
7
Width =
198
Left =
225
Height = 1
4
Top =
13
Width =
202
Caption = 'Destino para criação do caso de uso'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -247,10 +249,10 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
ParentFont = False
end
object btnSelecionarDestino: TSpeedButton
Left =
411
Height =
25
Top = 2
0
Width = 14
5
Left =
620
Height =
36
Top = 2
9
Width = 14
8
Caption = 'Selecionar destino'
Glyph.Data = {
36050000424D3605000000000000360400002800000010000000100000000100
...
...
@@ -299,28 +301,26 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
OnClick = btnSelecionarDestinoClick
end
object edtPackage: TEdit
Left =
8
Height = 2
2
Top = 2
3
Left =
225
Height = 2
9
Top = 2
9
Width = 393
Color = 15461355
ReadOnly = True
TabOrder = 0
end
end
object Panel2: TPanel
object edtUseCaseName: TEdit
Left = 8
Height = 56
Top = 288
Width = 206
ClientHeight = 56
ClientWidth = 206
Height = 29
Top = 29
Width = 198
TabOrder = 1
end
object Label4: TLabel
Left = 8
Height = 1
3
Top =
7
Width = 19
0
Height = 1
4
Top =
13
Width = 19
1
Caption = 'Nome no StarUML (case sensitive)'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -329,42 +329,36 @@ object CadastroCasoDeUso: TCadastroCasoDeUso
ParentColor = False
ParentFont = False
end
object edtUseCaseName: TEdit
Left = 8
Height = 22
Top = 23
Width = 198
TabOrder = 0
end
end
object Panel3: TPanel
Left = 0
Height =
39
Top =
356
Width = 78
1
Height =
55
Top =
401
Width = 78
2
Align = alBottom
ClientHeight =
39
ClientWidth = 78
1
TabOrder =
3
ClientHeight =
55
ClientWidth = 78
2
TabOrder =
2
object BitBtn1: TBitBtn
Left = 6
13
Height =
25
Left = 6
49
Height =
40
Top = 6
Width =
75
Width =
120
Anchors = [akTop, akLeft, akBottom]
Caption = 'Ok'
Default = True
DefaultCaption = True
Kind = bkOK
ModalResult = 1
OnClick = btnSalvarClick
TabOrder = 0
end
object BitBtn2: TBitBtn
Left =
701
Height =
25
Left =
522
Height =
40
Top = 6
Width =
75
Width =
120
Anchors = [akTop, akLeft, akBottom]
Caption = 'Cancel'
Cancel = True
DefaultCaption = True
Kind = bkCancel
ModalResult = 2
TabOrder = 1
...
...
EvoUMLPlugin/src/uCadastroCasoDeUso.pas
View file @
d36b4459
...
...
@@ -19,6 +19,8 @@ type
TCadastroCasoDeUso
=
class
(
TForm
)
BitBtn1
:
TBitBtn
;
BitBtn2
:
TBitBtn
;
edtUseCaseName
:
TEdit
;
Label4
:
TLabel
;
Panel3
:
TPanel
;
pnPrincipal
:
TPanel
;
lblNome
:
TLabel
;
...
...
@@ -41,9 +43,6 @@ type
edtPackage
:
TEdit
;
Label3
:
TLabel
;
btnSelecionarDestino
:
TSpeedButton
;
Panel2
:
TPanel
;
edtUseCaseName
:
TEdit
;
Label4
:
TLabel
;
Label5
:
TLabel
;
procedure
imgIconeClick
(
Sender
:
TObject
);
procedure
btnSelecionarDestinoClick
(
Sender
:
TObject
);
...
...
@@ -51,6 +50,7 @@ type
procedure
SpeedButton1Click
(
Sender
:
TObject
);
private
FOID
:
integer
;
FContextField
:
utField
;
fUMLUseCase
:
IUMLUseCase
;
fFormIcones
:
TCadastroCasoDeUsoIcones
;
fcxCadastroCasoDeUso
:
cxCadatroCasoDeUso
;
...
...
@@ -63,7 +63,8 @@ type
{ Private declarations }
public
{ Public declarations }
Constructor
Create
(
Sender
:
TComponent
;
piConnectionString
:
string
;
piUseCase
:
IUMLUseCase
);
reintroduce
;
Constructor
Create
(
Sender
:
TComponent
;
piCadatroCasoDeUso
:
cxCadatroCasoDeUso
;
piUseCase
:
IUMLUseCase
);
reintroduce
;
Destructor
Destroy
;
override
;
property
UseCasePackage
:
IUMLPackage
read
fUseCasePackage
write
fUseCasePackage
;
property
UseCase
:
IUMLUseCase
read
fUMLUseCase
;
...
...
@@ -81,15 +82,21 @@ uses IntegracaoDelphiSUML;
type
CP1252String
=
type
AnsiString
(
1252
);
constructor
TCadastroCasoDeUso
.
Create
(
Sender
:
TComponent
;
piC
onnectionString
:
string
;
piUseCase
:
IUMLUseCase
);
constructor
TCadastroCasoDeUso
.
Create
(
Sender
:
TComponent
;
piC
adatroCasoDeUso
:
cxCadatroCasoDeUso
;
piUseCase
:
IUMLUseCase
);
begin
inherited
Create
(
sender
);
fUMLUseCase
:=
piUseCase
;
fFormIcones
:=
TCadastroCasoDeUsoIcones
.
Create
(
self
);
fcxCadastroCasoDeUso
:=
cxCadatroCasoDeUso
.
Create
(
piConnectionString
)
;
fcxCadastroCasoDeUso
:=
piCadatroCasoDeUso
;
self
.
Initialize
;
end
;
destructor
TCadastroCasoDeUso
.
Destroy
;
begin
FreeAndNil
(
FContextField
);
inherited
Destroy
;
end
;
procedure
TCadastroCasoDeUso
.
imgIconeClick
(
Sender
:
TObject
);
begin
if
fFormIcones
.
ShowModal
=
mrOk
then
...
...
@@ -101,27 +108,25 @@ begin
end
;
procedure
TCadastroCasoDeUso
.
Initialize
;
var
l
Field
,
lResponseField
:
utField
;
l
UseCaseCode
:
string
;
var
l
UseCaseCode
:
string
;
l
RequestField
,
lResponseField
:
utField
;
begin
//Retorna do caso de uso os atributos da classe
lResponseField
:=
utField
.
Create
;
try
lField
:=
utField
.
Create
;
fcxCadastroCasoDeUso
.
rmObtemContexto
(
lField
,
lResponseField
);
SendToInterface
(
lResponseField
);
finally
// lResponseField.free;
end
;
FreeAndNil
(
FContextField
);
FContextField
:=
utField
.
Create
;
lRequestField
:=
utField
.
Create
;
fcxCadastroCasoDeUso
.
rmObtemContexto
(
lRequestField
,
FContextField
);
SendToInterface
(
FContextField
);
if
assigned
(
fUMLUseCase
)
then
begin
lField
:=
utField
.
Create
;
l
Request
Field
:=
utField
.
Create
;
lUseCaseCode
:=
fUMLUseCase
.
GetTaggedValueAsString
(
'DBMappings'
,
'DBUseCaseMap'
,
'Code'
);
lField
.
AddField
(
'CODIGO'
).
AsString
:=
lUseCaseCode
;
l
Request
Field
.
AddField
(
'CODIGO'
).
AsString
:=
lUseCaseCode
;
lResponseField
:=
utField
.
Create
;
try
fcxCadastroCasoDeUso
.
rmEditaObjeto
(
lField
,
lResponseField
);
fcxCadastroCasoDeUso
.
rmEditaObjeto
(
l
Request
Field
,
lResponseField
);
SendToInterface
(
lResponseField
);
finally
lResponseField
.
free
;
...
...
@@ -135,8 +140,8 @@ begin
begin
lResponseField
:=
utField
.
Create
;
try
lField
:=
utField
.
Create
;
fcxCadastroCasoDeUso
.
rmIncluiObjeto
(
lField
,
lResponseField
);
l
Request
Field
:=
utField
.
Create
;
fcxCadastroCasoDeUso
.
rmIncluiObjeto
(
l
Request
Field
,
lResponseField
);
SendToInterface
(
lResponseField
);
finally
lResponseField
.
free
;
...
...
@@ -162,19 +167,19 @@ begin
// lFieldCasoDeUso.AddAttribute('OID').AsInteger := FOID;
lFieldCasoDeUso
.
AddAttribute
(
'nome'
).
AsString
:=
edtNome
.
Text
;
lFieldCasoDeUso
.
AddAttribute
(
'descricao'
).
AsString
:=
edtDescricao
.
Text
;
if
cbxEntidade
.
ItemIndex
<>
-
1
then
lFieldCasoDeUso
.
AddAttribute
(
'idoentidade'
).
AsInteger
:=
integer
(
cbxEntidade
.
Items
.
Objects
[
cbxEntidade
.
ItemIndex
])
;
if
cbxCategoria
.
ItemIndex
<>
-
1
then
lFieldCasoDeUso
.
AddAttribute
(
'idocategoria'
).
AsInteger
:=
integer
(
cbxCategoria
.
Items
.
Objects
[
cbxCategoria
.
ItemIndex
])
;
if
assigned
(
fFormIcones
.
ltvIcones
.
Selected
)
then
lFieldCasoDeUso
.
AddAttribute
(
'idoicone'
).
AsInteger
:=
integer
(
fFormIcones
.
ltvIcones
.
Selected
.
Data
)
;
if
cbxEntidade
.
ItemIndex
<>
-
1
then
lFieldCasoDeUso
.
AddAttribute
(
'idoentidade'
).
AsInteger
:=
utAttribute
(
cbxEntidade
.
Items
.
Objects
[
cbxEntidade
.
ItemIndex
]).
AsInteger
;
if
cbxCategoria
.
ItemIndex
<>
-
1
then
lFieldCasoDeUso
.
AddAttribute
(
'idocategoria'
).
AsInteger
:=
utAttribute
(
cbxCategoria
.
Items
.
Objects
[
cbxCategoria
.
ItemIndex
]).
AsInteger
;
if
assigned
(
fFormIcones
.
ltvIcones
.
Selected
)
then
lFieldCasoDeUso
.
AddAttribute
(
'idoicone'
).
AsInteger
:=
utAttribute
(
fFormIcones
.
ltvIcones
.
Selected
.
Data
).
AsInteger
;
lFieldSistemas
:=
lFieldCasoDeUso
.
AddField
(
'sistemas'
);
for
I
:=
0
to
ltvSistema
.
Items
.
Count
-
1
do
if
ltvSistema
.
Items
[
i
].
Checked
then
lFieldSistemas
.
AddField
(
'ido'
).
AsInteger
:=
integer
(
ltvSistema
.
Items
[
i
].
Data
)
;
lFieldSistemas
.
AddField
(
'ido'
).
AsInteger
:=
utAttribute
(
ltvSistema
.
Items
[
i
].
Data
).
AsInteger
;
lFieldOperacoes
:=
lFieldCasoDeUso
.
AddField
(
'operacoes'
);
for
I
:=
0
to
ltvOperacao
.
Items
.
Count
-
1
do
if
ltvOperacao
.
Items
[
i
].
Checked
then
lFieldOperacoes
.
AddField
(
'ido'
).
AsInteger
:=
integer
(
ltvOperacao
.
Items
[
i
].
Data
)
;
lFieldOperacoes
.
AddField
(
'ido'
).
AsInteger
:=
utAttribute
(
ltvOperacao
.
Items
[
i
].
Data
).
AsInteger
;
end
;
procedure
TCadastroCasoDeUso
.
SendToInterface
(
piField
:
utField
);
...
...
@@ -392,7 +397,10 @@ begin
lElementSelector
.
ClearSelectableModels
();
lElementSelector
.
AddSelectableModel
(
'UMLPackage'
);
if
lElementSelector
.
Execute
(
'Selecione o local para criar o caso de uso'
)
then
begin
UseCasePackage
:=
lElementSelector
.
GetSelectedModel
as
IUMLPackage
;
edtPackage
.
Text
:=
UseCasePackage
.
PathName
;
end
;
end
;
procedure
TCadastroCasoDeUso
.
btnSalvarClick
(
Sender
:
TObject
);
...
...
@@ -414,12 +422,6 @@ begin
try
if
assigned
(
fUMLUseCase
)
then
begin
// if (assigned(fUseCasePackage.FindByName(edtUseCaseName.Text))) and (edtUseCaseName.Text <> fUMLUseCase.Name) then
// begin
// application.MessageBox('Caso de uso j existente no pacote selecionado.','StarUML', MB_ICONEXCLAMATION + MB_OK);
// exit;
// end;
SalvaObjeto
;
fUMLUseCase
.
Name
:=
edtUseCaseName
.
Text
;
end
...
...
EvoUMLPlugin/src/uCadastroCasoDeUsoIcones.dfm
View file @
d36b4459
object CadastroCasoDeUsoIcones: TCadastroCasoDeUsoIcones
Left =
0
Height = 4
05
Top =
0
Width =
497
Left =
726
Height = 4
12
Top =
329
Width =
501
Caption = 'Ícones'
ClientHeight = 405
ClientWidth = 497
Color = clBtnFace
ClientHeight = 412
ClientWidth = 501
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Position = poDesktopCenter
Position = poScreenCenter
LCLVersion = '2.0.0.4'
object Panel2: TPanel
Left = 0
Height = 3
66
Height = 3
57
Top = 0
Width =
497
Width =
501
Align = alClient
ClientHeight = 3
66
ClientWidth =
497
ClientHeight = 3
57
ClientWidth =
501
TabOrder = 0
object ltvIcones: TListView
Left = 1
Height = 3
64
Height = 3
55
Top = 1
Width = 49
5
Width = 49
9
Align = alClient
Columns = <
item
...
...
@@ -32,7 +32,9 @@ object CadastroCasoDeUsoIcones: TCadastroCasoDeUsoIcones
Width = 10
end>
HideSelection = False
LargeImages = imgListaIcone
ReadOnly = True
ScrollBars = ssAutoBoth
SortType = stText
TabOrder = 0
ViewStyle = vsIcon
...
...
@@ -41,31 +43,33 @@ object CadastroCasoDeUsoIcones: TCadastroCasoDeUsoIcones
end
object Panel1: TPanel
Left = 0
Height =
39
Top = 3
66
Width =
497
Height =
55
Top = 3
57
Width =
501
Align = alBottom
ClientHeight =
39
ClientWidth =
497
ClientHeight =
55
ClientWidth =
501
TabOrder = 1
object BitBtn1: TBitBtn
Left = 3
28
Height =
25
Top =
8
Width =
75
Left = 3
71
Height =
40
Top =
6
Width =
120
Anchors = [akTop, akLeft, akBottom]
Caption = 'Ok'
Default = True
DefaultCaption = True
Kind = bkOK
ModalResult = 1
TabOrder = 0
end
object BitBtn2: TBitBtn
Left =
416
Height =
25
Top =
8
Width =
75
Left =
244
Height =
40
Top =
6
Width =
120
Anchors = [akTop, akLeft, akBottom]
Caption = 'Cancel'
Cancel = True
DefaultCaption = True
Kind = bkCancel
ModalResult = 2
TabOrder = 1
...
...
@@ -73,7 +77,7 @@ object CadastroCasoDeUsoIcones: TCadastroCasoDeUsoIcones
end
object imgListaIcone: TImageList
Height = 32
S
hareImages
= True
S
caled
= True
Width = 32
left = 440
top = 56
...
...
EvoUMLPlugin/src/uCadastroClasse.dfm
View file @
d36b4459
object CadastroClasse: TCadastroClasse
Left =
0
Height = 3
13
Top =
0
Width = 50
3
Left =
308
Height = 3
45
Top =
249
Width = 50
4
BorderStyle = bsDialog
Caption = 'Cadastro de Classe'
ClientHeight = 313
ClientWidth = 503
Color = clBtnFace
ParentFont = True
Position = poDesktopCenter
ClientHeight = 345
ClientWidth = 504
Position = poScreenCenter
LCLVersion = '2.0.0.4'
object Panel1: TPanel
Left = 0
Height = 3
13
Height = 3
45
Top = 0
Width = 50
3
Width = 50
4
Align = alClient
ClientHeight = 3
13
ClientWidth = 50
3
ClientHeight = 3
45
ClientWidth = 50
4
TabOrder = 0
object Panel3: TPanel
Left = 6
Height = 123
Top = 141
Width = 490
ClientHeight = 123
ClientWidth = 490
Left = 1
Height = 130
Top = 140
Width = 502
Align = alTop
ClientHeight = 130
ClientWidth = 502
TabOrder = 2
object Panel5: TPanel
Left = 0
Height =
48
Height =
103
Top = 16
Width = 200
ClientHeight =
48
ClientHeight =
103
ClientWidth = 200
TabOrder = 0
object Label4: TLabel
Left = 8
Height = 1
3
Height = 1
4
Top = 5
Width = 153
Caption = 'Nome da classe no StarUML'
...
...
@@ -50,7 +50,7 @@ object CadastroClasse: TCadastroClasse
end
object edtNomeStarUML: TEdit
Left = 8
Height = 2
2
Height = 2
9
Top = 21
Width = 184
TabOrder = 0
...
...
@@ -58,39 +58,39 @@ object CadastroClasse: TCadastroClasse
end
object GroupBox1: TGroupBox
Left = 216
Height =
96
Height =
103
Top = 16
Width = 270
Caption = 'DB Mappings'
ClientHeight =
74
ClientWidth = 26
2
ClientHeight =
83
ClientWidth = 26
8
TabOrder = 1
object Label1: TLabel
Left = 6
Height = 1
6
Height = 1
9
Top = 14
Width =
39
Width =
41
Caption = 'Table:'
ParentColor = False
end
object Label2: TLabel
Left = 0
Height = 1
6
Height = 1
9
Top = 47
Width =
45
Width =
51
Caption = 'DBIDO:'
ParentColor = False
end
object edtDBTableName: TEdit
Left = 46
Height = 2
2
Height = 2
9
Top = 8
Width = 210
TabOrder = 0
end
object edtDBIDO: TEdit
Left = 46
Height = 2
2
Height = 2
9
Top = 41
Width = 210
TabOrder = 1
...
...
@@ -98,18 +98,19 @@ object CadastroClasse: TCadastroClasse
end
end
object Panel2: TPanel
Left = 6
Height = 56
Top = 79
Width = 490
ClientHeight = 56
ClientWidth = 490
Left = 1
Height = 65
Top = 75
Width = 502
Align = alTop
ClientHeight = 65
ClientWidth = 502
TabOrder = 1
object Label3: TLabel
Left = 7
Height = 1
3
Height = 1
4
Top = 8
Width = 1
67
Width = 1
71
Caption = 'Destino para criação da classe'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -120,8 +121,8 @@ object CadastroClasse: TCadastroClasse
end
object btnSelecionarDestino: TSpeedButton
Left = 333
Height =
25
Top = 2
0
Height =
34
Top = 2
4
Width = 151
Caption = 'Selecionar destino'
Glyph.Data = {
...
...
@@ -172,7 +173,7 @@ object CadastroClasse: TCadastroClasse
end
object edtPackage: TEdit
Left = 7
Height = 2
2
Height = 2
9
Top = 23
Width = 321
Color = 15461355
...
...
@@ -181,18 +182,19 @@ object CadastroClasse: TCadastroClasse
end
end
object Panel4: TPanel
Left = 6
Height = 66
Top = 8
Width = 490
ClientHeight = 66
ClientWidth = 490
Left = 1
Height = 74
Top = 1
Width = 502
Align = alTop
ClientHeight = 74
ClientWidth = 502
TabOrder = 0
object lblNome: TLabel
Left = 97
Height = 1
3
Height = 1
4
Top = 13
Width = 12
2
Width = 12
4
Caption = 'Nome (case sensitive)'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -203,17 +205,17 @@ object CadastroClasse: TCadastroClasse
end
object lblValorCodigo: TLabel
Left = 9
Height = 1
6
Height = 1
9
Top = 32
Width = 9
3
Width = 9
7
Caption = 'lblValorCodigo'
ParentColor = False
end
object lblCodigo: TLabel
Left = 9
Height = 1
3
Height = 1
4
Top = 13
Width = 3
8
Width = 3
9
Caption = 'Código'
Font.Color = clWindowText
Font.Height = -11
...
...
@@ -224,7 +226,7 @@ object CadastroClasse: TCadastroClasse
end
object edtNome: TEdit
Left = 96
Height = 2
2
Height = 2
9
Top = 32
Width = 390
OnChange = edtNomeChange
...
...
@@ -233,32 +235,33 @@ object CadastroClasse: TCadastroClasse
end
object Panel7: TPanel
Left = 1
Height =
39
Top = 2
73
Width = 50
1
Height =
55
Top = 2
89
Width = 50
2
Align = alBottom
ClientHeight =
39
ClientWidth = 50
1
ClientHeight =
55
ClientWidth = 50
2
TabOrder = 3
object BitBtn1: TBitBtn
Left = 3
28
Height =
25
Left = 3
69
Height =
40
Top = 8
Width =
75
Width =
120
Anchors = [akTop, akLeft, akBottom]
Caption = 'Ok'
Default = True
DefaultCaption = True
Kind = bkOK
ModalResult = 1
OnClick = btnSalvarClick
TabOrder = 0
end
object BitBtn2: TBitBtn
Left =
416
Height =
25
Left =
242
Height =
40
Top = 8
Width =
75
Width =
120
Anchors = [akTop, akLeft, akBottom]
Caption = 'Cancel'
Cancel = True
DefaultCaption = True
Kind = bkCancel
ModalResult = 2
TabOrder = 1
...
...
EvoUMLPlugin/src/uCadastroClasse.pas
View file @
d36b4459
...
...
@@ -56,7 +56,7 @@ type
procedure
Initialize
;
public
{ Public declarations }
Constructor
Create
(
Sender
:
TComponent
;
piC
onnectionString
:
string
;
piUMLClass
:
IUMLCLass
);
reintroduce
;
Constructor
Create
(
Sender
:
TComponent
;
piC
adastroClasse
:
cxCadastroClasse
;
piUMLClass
:
IUMLCLass
);
reintroduce
;
property
ClassPackage
:
IUMLPackage
read
fClassPackage
write
fClassPackage
;
property
UMLClass
:
IUMLClass
read
fUMLClass
write
fUMLClass
;
...
...
@@ -73,7 +73,7 @@ uses IntegracaoDelphiSUML;
{ TCadastroClasse }
constructor
TCadastroClasse
.
Create
(
Sender
:
TComponent
;
piC
onnectionString
:
string
;
piUMLClass
:
IUMLCLass
);
constructor
TCadastroClasse
.
Create
(
Sender
:
TComponent
;
piC
adastroClasse
:
cxCadastroClasse
;
piUMLClass
:
IUMLCLass
);
begin
inherited
Create
(
sender
);
...
...
@@ -83,7 +83,7 @@ begin
edtDBIDO
.
Text
:=
fUMLClass
.
GetTaggedValueAsString
(
'DBMappings'
,
'DBClassMap'
,
'DBIDO'
);
edtDBTableName
.
Text
:=
fUMLClass
.
GetTaggedValueAsString
(
'DBMappings'
,
'DBClassMap'
,
'Table'
);
end
;
fcxCadastroClasse
:=
cxCadastroClasse
.
Create
(
piConnectionString
)
;
fcxCadastroClasse
:=
piCadastroClasse
;
self
.
Initialize
;
end
;
...
...
@@ -94,17 +94,17 @@ var lUMLFactory: IUMLFactory;
begin
if
edtNomeStarUML
.
Text
=
''
then
begin
application
.
MessageBox
(
'
necess
rio informar o nome da classe no StarUML.'
,
'StarUML'
,
MB_ICONEXCLAMATION
+
MB_OK
);
application
.
MessageBox
(
'
É necessá
rio informar o nome da classe no StarUML.'
,
'StarUML'
,
MB_ICONEXCLAMATION
+
MB_OK
);
exit
;
end
else
if
edtPackage
.
Text
=
''
then
begin
application
.
MessageBox
(
'
necessrio informar o package onde ser
criado o caso de uso.'
,
'StarUML'
,
MB_ICONEXCLAMATION
+
MB_OK
);
application
.
MessageBox
(
'
É necessário informar o package onde será
criado o caso de uso.'
,
'StarUML'
,
MB_ICONEXCLAMATION
+
MB_OK
);
exit
;
end
;
try
//Se em modo de edi
o (classe j
criada)
//Se em modo de edi
ção (classe já
criada)
if
assigned
(
fUMLClass
)
then
begin
SalvaObjeto
;
...
...
@@ -114,10 +114,10 @@ begin
end
else
begin
//Seno cria o objeto no StarUML e salva no caso de uso
//Sen
ã
o cria o objeto no StarUML e salva no caso de uso
if
assigned
(
fClassPackage
.
FindByName
(
edtNomeStarUML
.
Text
))
then
begin
application
.
MessageBox
(
'Classe j existente no pacote selecionado.'
,
'StarUML'
,
MB_ICONEXCLAMATION
+
MB_OK
);
application
.
MessageBox
(
'Classe j
á
existente no pacote selecionado.'
,
'StarUML'
,
MB_ICONEXCLAMATION
+
MB_OK
);
exit
;
end
;
...
...
@@ -158,8 +158,11 @@ begin
lElementSelector
.
ClearSelectableModels
();
lElementSelector
.
AddSelectableModel
(
'UMLPackage'
);
lElementSelector
.
AddSelectableModel
(
'UMLModel'
);
if
lElementSelector
.
Execute
(
'Selecione o local para criar o caso de uso'
)
then
if
lElementSelector
.
Execute
(
'Selecione o local para criar a classe'
)
then
begin
ClassPackage
:=
lElementSelector
.
GetSelectedModel
as
IUMLPackage
;
edtPackage
.
caption
:=
ClassPackage
.
PathName
;
end
;
end
;
procedure
TCadastroClasse
.
edtNomeChange
(
Sender
:
TObject
);
...
...
@@ -182,8 +185,8 @@ var lField, lResponseField: utField;
lClassCode
:
string
;
begin
FOID
:=
-
1
;
//Se for edio, seta o contexto no caso de uso (cadastro de classe )para a classe corrente
// atraves do cdigo
//Se for edi
çã
o, seta o contexto no caso de uso (cadastro de classe )para a classe corrente
// atraves do c
ó
digo
if
assigned
(
fUMLClass
)
then
begin
lField
:=
utField
.
Create
;
...
...
EvoUMLPlugin/src/uDBAttributeParameters.dfm
View file @
d36b4459
object fDBAttributeParameters: TfDBAttributeParameters
Left = 0
Height = 35
9
Top =
0
Height = 35
3
Top =
27
Width = 348
BorderStyle = bsDialog
Caption = 'fDBAttributeParameters'
ClientHeight = 35
9
ClientHeight = 35
3
ClientWidth = 348
Color = clBtnFace
Font.Color = clWindowText
...
...
@@ -44,7 +44,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
object Panel2: TPanel
Left = 0
Height = 44
Top = 3
15
Top = 3
09
Width = 348
Align = alBottom
ClientHeight = 44
...
...
@@ -52,7 +52,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
TabOrder = 1
object ckbCheckLength: TCheckBox
Left = 9
Height =
3
3
Height =
2
3
Top = 6
Width = 88
Caption = 'Check length'
...
...
@@ -98,11 +98,11 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object Panel3: TPanel
Left = 0
Height = 28
8
Height = 28
2
Top = 27
Width = 348
Align = alClient
ClientHeight = 28
8
ClientHeight = 28
2
ClientWidth = 348
TabOrder = 0
object GroupBox1: TGroupBox
...
...
@@ -111,14 +111,14 @@ object fDBAttributeParameters: TfDBAttributeParameters
Top = 6
Width = 323
Caption = 'Attribute (StarUML)'
ClientHeight =
85
ClientWidth = 32
3
ClientHeight =
70
ClientWidth = 32
1
TabOrder = 0
object Label5: TLabel
Left = 12
Height = 16
Top = 54
Width = 3
3
Width = 3
2
Caption = 'Type:'
Font.Color = clWindowText
Font.Height = -13
...
...
@@ -140,13 +140,13 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object cbbStarUMLTypes: TComboBox
Left = 52
Height = 2
4
Height = 2
8
Top = 50
Width = 249
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Tahoma'
ItemHeight =
16
ItemHeight =
0
OnClick = cbbStarUMLTypesClick
ParentFont = False
Style = csDropDownList
...
...
@@ -154,7 +154,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object edtAttributeName: TEdit
Left = 52
Height =
24
Height =
33
Top = 20
Width = 249
Font.Color = clWindowText
...
...
@@ -171,8 +171,8 @@ object fDBAttributeParameters: TfDBAttributeParameters
Top = 97
Width = 323
Caption = 'DB Mappings'
ClientHeight = 1
84
ClientWidth = 32
3
ClientHeight = 1
69
ClientWidth = 32
1
TabOrder = 1
object Label1: TLabel
Left = 16
...
...
@@ -190,7 +190,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
Left = 21
Height = 16
Top = 62
Width = 3
3
Width = 3
2
Caption = 'Type:'
Font.Color = clWindowText
Font.Height = -13
...
...
@@ -224,7 +224,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object lblAttLength: TLabel
Left = 290
Height = 1
3
Height = 1
4
Top = 35
Width = 58
Caption = 'lblAttLength'
...
...
@@ -232,9 +232,9 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object ckbMand: TCheckBox
Left = 18
Height =
17
Height =
23
Top = 159
Width =
97
Width =
86
Caption = 'Mandatory'
Font.Color = clWindowText
Font.Height = -13
...
...
@@ -244,7 +244,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object edtName: TEdit
Left = 67
Height =
24
Height =
33
Top = 29
Width = 214
Font.Color = clWindowText
...
...
@@ -256,7 +256,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object edtFSize: TEdit
Left = 67
Height =
24
Height =
33
Top = 89
Width = 78
Font.Color = clWindowText
...
...
@@ -267,7 +267,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object edtVSize: TEdit
Left = 67
Height =
24
Height =
33
Top = 119
Width = 78
Font.Color = clWindowText
...
...
@@ -284,7 +284,7 @@ object fDBAttributeParameters: TfDBAttributeParameters
Font.Color = clWindowText
Font.Height = -13
Font.Name = 'Tahoma'
ItemHeight =
16
ItemHeight =
0
Items.Strings = (
'CHAR'
'DATETIME'
...
...
@@ -302,9 +302,9 @@ object fDBAttributeParameters: TfDBAttributeParameters
end
object ckbIsAuditable: TCheckBox
Left = 154
Height =
17
Height =
23
Top = 159
Width =
97
Width =
80
Caption = 'IsAuditable'
TabOrder = 5
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment