I'm using Avalonedit in my wcf application. I have to implement code completion feature(intellisense).
My Requirement
I have an xml file with the following content.This xml data will be updated often.
<?xml version="1.0" encoding="UTF-8"?>
<RelativeRegion>
<Display_Window>
<GreenButton>10,10,30,85</GreenButton>
</Display_Window>
<Insert_Window>
<BlueButton>10,10,30,85</BlueButton>
<YellowButton>10,10,30,85</YellowButton>
</Insert_Window>
<Search_Window>
<RedButton>10,10,30,85</RedButton>
<YellowButton>10,10,30,85</YellowButton>
</Search_Window>
</RelativeRegion>
I want to insert intellisense for this data to my avalon editor like
RelativeRegion.Display_Window.GreenButton
Is it possible to directly bind the xml data to avalonedit intellisense?
Is there any way to implement this nested code completion?
What I have done so far
I googled a lot about avalonedit nested code completion and i didn't get anything about the nested thing. Finally I start with the available code from AvalonEdit Code Completion Documentation. But I think this will work only for single level and not suiting for my requirement. May be I am unaware of its the capabilities as a first time user of avalonedit.
Anyone tried the nested code completion. Is there any way to achieve this.
I can change the data format from xml to JSON or any other format if required.
Related
I have currently a simple standard job on Talend doing this :
It simply reads a file of several lines (tHDFSInput), and for each line of this file (tFlowToIterate), I create a INSERT query "INSERT ... SELECT ... FROM" based on what I read in my file (tHiveRow). And it works well, it's just a bit slow.
I now need to modify my "Standard" job to make a "Big Data Batch" job in order to make it faster, and also because we asked me to only make Big Data Batch from now on.
The thing is that there is no tFlowToIterate and no tHiveRow component with Big Data Batch...
How can I do this ?
Thank's a lot.
Though I haven't tried this solution, I think this can help you.
Create hive table upfront.
Place tHDFSConfiguration component in the job and provide cluster details.
Use tFileInputDelimited component. On providing storage configuration as tHDFSConfiguration(defined in step1), this will read from HDFS.
Use tHiveOutput component. Connect tFileInputDelimited to tHiveOutput. In tHiveOutput, you can provide the table, format and save mode.
In order to load HDFS into Hive without modification on the data maybe you can use only one component : tHiveLoad
Insert your HDFS path inside the component.
tHiveLoad documentation : https://help.talend.com/reader/hCrOzogIwKfuR3mPf~LydA/ILvaWaTQF60ovIN6jpZpzg
A the moment when I execute some tests, I can see only the failed assertions in the result tree listener.
Since I would like to do functional testing with this tools, I need to have all passed validations included in the report.
Is it possible in the new version of Jmeter?
You can "tell" JMeter to store results as XML - it will trigger saving assertion results in .jtl file
To switch JMeter results file to XML and store all assertion results add the next two lines to user.properties file:
jmeter.save.saveservice.output_format=xml
jmeter.save.saveservice.assertion_results=all
You'll get output like:
<?xml version="1.0" encoding="UTF-8"?>
<testResults version="1.2">
<httpSample t="340" lt="340" ts="1430219540110" s="true" lb="HTTP Request" rc="200" rm="OK" tn="Thread Group 1-1" dt="text" by="1591" ng="1" na="1">
<assertionResult>
<name>Response Assertion</name>
<failure>false</failure>
<error>false</error>
</assertionResult>
</httpSample>
See Apache JMeter Properties Customization Guide for more information on JMeter properties and ways of controlling them.
I'm developing a REST API that uses Spring MVC. The objects I consume and produce are generated (using JAXB) from NCPDP (http://www.ncpdp.org/) XSDs. I have everything working when requests come in, but I'd like to add additional attributes to the root element on outgoing requests.
Right now, my outgoing response looks as follows:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<transport:Message xmlns:transport="http://www.ncpdp.org/schema/transport">
<transport:Header>
...
</transport:Header>
<transport:Body>
<transport:Status>
<transport:Code>010</transport:Code>
<transport:Description>OK</transport:Description>
</transport:Status>
</transport:Body>
</transport:Message>
And it should look as follows:
<?xml version="1.0"?>
<transport:Message xmlns:transport="http://www.ncpdp.org/schema/transport" xmlns:datatypes="http://www.ncpdp.org/schema/datatypes"
xmlns:script="http://www.ncpdp.org/schema/script" xmlns:structures="http://www.ncpdp.org/schema/structures"
xmlns:pa-structures="http://www.ncpdp.org/schema/pa-structures" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
StructuresVersion="v2014041" ECLVersion="v2014041" DatatypesVersion="v2014041" PA-StructuresVersion="v2014041"
TransactionVersion="v2014041" TransportVersion="v2014041" TransactionDomain="SCRIPT">
<transport:Header>
...
</transport:Header>
<transport:Body>
<transport:Status>
<transport:Code>010</transport:Code>
</transport:Status>
</transport:Body>
</transport:Message>
I don't believe I need all the namespaces defined (since they're not used), but I do need the StructuresVersion and all other attributes. Is there a way to modify my bindings.xjb to include these attributes? Or do I have to copy the generated code into my source tree and add annotations to do this?
Thanks,
Matt
Since these attribute are declared in your XML schema, you should be getting appropriate properties in your schema-derived code.
It actually does not matter if this is a root element or some child element. Please re-check the generated code, look for something like getStructuresVersion(). So you don't need to do anything.
As for the namespaces, you will get them automatically declared, when you marshal. But you may first get them declared as ns0, ns1 etc. which is not very nice in terms of readability. Please see the following question:
Controlling namespace prefixes in JAXB
(the question itself, not the answers) for information on how to control these prefixes with a custom prefix mapper or this post by Blaise Doughan.
Is there a way to open a specified document, eg "production order 123" or form, eg "purchase orders" in Ax2012 from an external application directly?
In detail, I'm looking for something similiar like AXPath, but this doesn't work with versions greater then 2009.
Is there any ( maybe included ) way to achieve this?
There is! It's using AX's drilldown functionality which uses AxHLink.exe to handle dynamics:// URLs, which are passed to the Classes\SysStartupCmd function. You could also create some custom code there if you wanted to launch the AX client executable directly.
My question I asked some while back should have a great deal of useful information in it here:
What handles dynamics:// URLs?
Some more can be found: http://technet.microsoft.com/en-us/library/aa834337.aspx
EDIT:
It sounds like you are confused or the posts weren't clear enough. I think you have 3 basic options.
Dynamics:// URLs are handled by AxHLink.exe and they only seem to handle drilldown, viewalert, and viewalertrule. So if you want to use Dynamics:// URLs, you will need to hi-jack those somehow. There is a pastbin from Jan in that other stack post.
Create a custom URI handler and event poller (lot of work) see http://axcoder.blogspot.dk/2010/10/how-to-open-form-in-running-ax-from.html
Extend SysStartupCmd and then instead of using Dynamics:// URLs, just call Ax32.exe -startupCmd directly and a parameter can be passed to your custom class.
I am using Tridion 2011 SP1, And I am creating workflow like start-->create-->Review-->publish--Stop.
I created and registered the class library, and invoke the C# method using VBscript (Script Editor of WF Tab) as given below.
Option Explicit
Dim workflowHandler
Set workflowHandler= CreateObject("CoreComponentWorkflow.WorkflowHandler")
If Not workflowHandler Is Nothing Then
Call workflowHandler.PublishComponent(Cstr(CurrentWorkItem.ID))
FinishActivity "Published to WIP"
End If
Set workflowHandler= Nothing
Is the above code is correct? I am sure I am able to create object using the below line.
Set workflowHandler= CreateObject("CoreComponentWorkflow.WorkflowHandler")
And currently I am publishing the current item only using the C# code, am calling the C# function as below.
Call workflowHandler.PublishComponent(Cstr(CurrentWorkItem.ID))
After publishing the item, I am finishing the activity using below.
FinishActivity "Published to WIP"
I have checked the above code directly in the server by hard coding the currentworkitem, it was working fine. But when I put the same code in vbscript editor, the item is not published.
Can any one suggest on this?
When you hardcode you might be adding the TCM ID directly so it is working properly, which means that CurrentWorkItem.ID is not the correct API call to get the Component ID. See Igor comment below to get the tcm id.