Skip to content

Commit cd9fea2

Browse files
committed
Refactoring package definition code for BaseMethodRequest to utilize method for IBaseMethodRequest
1 parent 7a531fa commit cd9fea2

File tree

1 file changed

+1
-18
lines changed

1 file changed

+1
-18
lines changed

Templates/Java/BaseJavaModel.template.tt

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -618,25 +618,8 @@
618618
public string CreatePackageDefForBaseMethodRequest(CustomT4Host host)
619619
{
620620
var sb = new StringBuilder();
621-
sb.Append(CreatePackageDefinition(host));
621+
sb.Append(CreatePackageDefForIBaseMethodRequest(host));
622622
var importFormat = @"import {0}.{1}.{2};";
623-
624-
var returnType = ReturnType(host.CurrentType);
625-
if(returnType != "Void" && !(host.CurrentType.AsOdcmMethod().ReturnType is OdcmPrimitiveType))
626-
{
627-
sb.AppendFormat(importFormat,
628-
host.CurrentModel.NamespaceName(),
629-
"models.extensions",
630-
ReturnType(host.CurrentType));
631-
sb.Append("\n");
632-
}
633-
634-
sb.AppendFormat(importFormat,
635-
host.CurrentModel.NamespaceName(),
636-
"requests.extensions",
637-
ITypeRequest(host.CurrentType));
638-
sb.Append("\n");
639-
640623
sb.AppendFormat(importFormat,
641624
host.CurrentModel.NamespaceName(),
642625
"requests.extensions",

0 commit comments

Comments
 (0)