Search Results

Search found 25579 results on 1024 pages for 'complex event processing'.

Page 44/1024 | < Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >

  • Return data from subroutine while the subroutine is still processing

    - by Perl QuestionAsker
    Is there any way to have a subroutine send data back while still processing? For instance (this example used simply to illustrate) - a subroutine reads a file. While it is reading through the file, if some condition is met, then "return" that line and keep processing. I know there are those that will answer - why would you want to do that? and why don't you just ...?, but I really would like to know if this is possible. Thank you so much in advance.

    Read the article

  • Need multiple views to respond to a touch event in an iPhone app

    - by Joel
    Setup: I have two views that I need to respond to the touch event, and they are layered out on top of one another. View 1 is on top of View 2. View 2 is a UIWebView. View 1 is sublclassed to capture the touch event. My problem is that if I try to call the UIWebView event handlers (touchesBegan: and touchesEnded:) from within the event handlers of View 1, which is the first responder, nothing happens. However if I set View 1 to userInteractionEnabled = NO, then the touch goes through that view and is processed properly by the 2nd view. Any ideas on how I can have 2 views respond to a touch event? Unfortunately the 2nd view is a UIWebView, so I need to actually call the event handler and not a different method, etc... Thanks in advance for any advice, Joel

    Read the article

  • Parse Complex WSDL Parameter Information in C#

    - by jaws
    I am attempting to parse WSDL, along the lines of the example given here. The author notes, in the comments, that the example is not capable of drilling down into complex data types. And in fact, when I run the example, it does not appear to even handle simple data types. I have poked around in System.Web.Services.Description.ServiceDescription class, which is used in the example, but cannot find any actual parameter or return type information at run-time. I gather that I may need to do some manual parsing of an xsd file? Both google and stackoverflow appear to lack a complete example of how to drill down into complex types programmatically, so... how should I do this?

    Read the article

  • How to generate complex url like stackoverflow?

    - by Freewind
    I'm using playframework, and I hope to generate complex urls like stackoverflow. For example, I want to generate a question's url: http://aaa.com/questions/123456/How-to-generator-a-complex-url Note the last part, it's the title of the question. But I don't know how to do it. UPDATED In the playframework, we can define routes in conf/routes file, and what I do is: GET /questions/{<\d+>id} Questions.show In this way, when we call @{Questions.show(id)} in views, it will generate: http://aaa.com/questions/123456 But how to let the generated has a title part, is difficult.

    Read the article

  • raising a vb6 event using interop

    - by Steve
    Hi, I have a legacy VB6 component that I've imported into VS using tlbimp.exe to generate my interop assembly. The VB6 component defines an event that allows me to pass messages within VB6. Public Event Message(ByVal iMsg As Variant, oCancel As Variant) I would really like to be able to raise this even in my C# program, but its getting imported as an event, not a delegate or something else useful. So, I can only listen, but never fire. Does anyone know how to fire an event contained within VB6? The C# event looks like [TypeLibType(16)] [ComVisible(false)] public interface __MyObj_Event { event __MyObj_MessageEventHandler Message; } I unfortunately cannot change the VB6 code. Thanks.

    Read the article

  • Correct way of using/testing event service in Eclipse E4 RCP

    - by Thorsten Beck
    Allow me to pose two coupled questions that might boil down to one about good application design ;-) What is the best practice for using event based communication in an e4 RCP application? How can I write simple unit tests (using JUnit) for classes that send/receive events using dependency injection and IEventBroker ? Let’s be more concrete: say I am developing an Eclipse e4 RCP application consisting of several plugins that need to communicate. For communication I want to use the event service provided by org.eclipse.e4.core.services.events.IEventBroker so my plugins stay loosely coupled. I use dependency injection to inject the event broker to a class that dispatches events: @Inject static IEventBroker broker; private void sendEvent() { broker.post(MyEventConstants.SOME_EVENT, payload) } On the receiver side, I have a method like: @Inject @Optional private void receiveEvent(@UIEventTopic(MyEventConstants.SOME_EVENT) Object payload) Now the questions: In order for IEventBroker to be successfully injected, my class needs access to the current IEclipseContext. Most of my classes using the event service are not referenced by the e4 application model, so I have to manually inject the context on instantiation using e.g. ContextInjectionFactory.inject(myEventSendingObject, context); This approach works but I find myself passing around a lot of context to wherever I use the event service. Is this really the correct approach to event based communication across an E4 application? how can I easily write JUnit tests for a class that uses the event service (either as a sender or receiver)? Obviously, none of the above annotations work in isolation since there is no context available. I understand everyone’s convinced that dependency injection simplifies testability. But does this also apply to injecting services like the IEventBroker? This article describes creation of your own IEclipseContext to include the process of DI in tests. Not sure if this could resolve my 2nd issue but I also hesitate running all my tests as JUnit Plug-in tests as it appears impractible to fire up the PDE for each unit test. Maybe I just misunderstand the approach. This article speaks about “simply mocking IEventBroker”. Yes, that would be great! Unfortunately, I couldn’t find any information on how this can be achieved. All this makes me wonder whether I am still on a "good path" or if this is already a case of bad design? And if so, how would you go about redesigning? Move all event related actions to dedicated event sender/receiver classes or a dedicated plugin?

    Read the article

  • Error processing response in .net web service with WSE3 mutualCertificate10Security Assertion

    - by Maeloc
    I am securing a .net web service (framework 2.0) with WSE3 mutualCertificate10Security Assertion. When request are valid all is fine and the response is wellformed, but when the request is invalid (cause a invalid signature, failed check, or soapexception thrown), the web server isn't able to process the response to send to the client. The error in application event log is: An error occured processing an outgoing fault response. Details of the error causing the processing failure: System.InvalidOperationException: Send security filter on the server could not retrieve the operation protection requirements from the operation state. en Microsoft.Web.Services3.Security.SecureConversationServiceSendSecurityFilter.SecureMessage(SoapEnvelope envelope, Security security) en Microsoft.Web.Services3.Security.SendSecurityFilter.ProcessMessage(SoapEnvelope envelope) en Microsoft.Web.Services3.Pipeline.ProcessOutputMessage(SoapEnvelope envelope) en Microsoft.Web.Services3.WseProtocol.GetFilteredResponseEnvelope(SoapEnvelope outputEnvelope) All certificate permissions are OK (when request is OK the web service is able to sign the response). Error occurs only if a soapFault must be returned in the response. Any ideas?

    Read the article

  • flex 3 cancel tooltip event

    - by gmoniey
    I am trying to cancel a tooltip event (I only want it to display when the mouse is hovered over a certain area), and can't seem to figure it out. I tried stopPropagation, preventDefault, and stopImmediatePropagation, but none of them seem to work. Here the code I am using: private function toolTipCreateHandler(event:ToolTipEvent):void { if(event.currentTarget.mouseX < 130) { var tooltip:PhotoToolTip = new PhotoToolTip(); tooltip.src = event.currentTarget.toolTip; event.toolTip = tooltip; } else { event.stopImmediatePropagation(); } } Any ideas? Thanks

    Read the article

  • How to add some complex structure in multiple places in an XML file

    - by Guillaume
    I have an XML file which has many section like the one below: <Operations> <Action [some attributes ...]> [some complex content ...] </Action> <Action [some attributes ...]> [some complex content ...] </Action> </Operations> I have to add an <Action/> to every <Operations/>. It seems that an XSLT should be a good solution to this problem: <xsl:template match="Operations/Action[last()]"> <xsl:copy> <xsl:apply-templates select="@*|node()"/> </xsl:copy> <Action>[some complex content ...]</Action> </xsl:template> <xsl:template match="@*|node()"> <xsl:copy> <xsl:apply-templates select="@*|node()"/> </xsl:copy> </xsl:template> My problem is that the content of my <Action/> contains some xPath expressions. For example: <Action code="p_histo01"> <customScript languageCode="gel"> <gel:script xmlns:core="jelly:core" xmlns:gel="jelly:com.niku.union.gel.GELTagLibrary" xmlns:soap="jelly:com.niku.union.gel.SOAPTagLibrary" xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sql="jelly:sql" xmlns:x="jelly:xml" xmlns:xog="http://www.niku.com/xog" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <sql:param value="${gel_stepInstanceId}"/> </gel:script> </customScript> </Action> The ${gel_stepInstanceId} is interpreted by my XSLT but I would like it to be copied as-is. Is that possible? How?

    Read the article

  • Enable PyGTK Eventbox motion-notify-event while is a Layout child

    - by mkotechno
    I noticed when a Eventbox is added into a Layout some events are missed, this does not happend for example adding it to a Fixed (very similar widget), I tried to restore the event mask in this way with no sucess: import pygtk import gtk def foo(widget, event): print event pygtk.require('2.0') window = gtk.Window(gtk.WINDOW_TOPLEVEL) window.connect('destroy', lambda x: gtk.main_quit()) eventbox = gtk.EventBox() eventbox.connect('button-press-event', foo) # works eventbox.connect('motion-notify-event', foo) # fail eventbox.set_events( gtk.gdk.BUTTON_MOTION_MASK| # restoring missed masks gtk.gdk.BUTTON1_MOTION_MASK| gtk.gdk.BUTTON2_MOTION_MASK| gtk.gdk.BUTTON3_MOTION_MASK) layout = gtk.Layout() image = gtk.image_new_from_file('/home/me/picture.jpg') layout.add(image) eventbox.add(layout) window.add(eventbox) window.show_all() gtk.main() How should I restore the missed event/mask?

    Read the article

  • LINQ to SQL: On load processing of lazy loaded associations

    - by Matt Holmes
    If I have an object that lazy loads an association with very large objects, is there a way I can do processing at the time the lazy load occurs? I thought I could use AssociateWith or LoadWith from DataLoadOptions, but there are very, very specific restrictions on what you can do in those. Basically I need to be notified when an EntitySet< decides it's time to load the associated object, so I can catch that event and do some processing on the loaded object. I don't want to simply walk through the EntitySet when I load the parent object, because that will force all the lazy loaded items to load (defeating the purpose of lazy loading entirely).

    Read the article

  • Processing a property in linq to sql

    - by Mostafa
    Hi It's my first LINQ TO SQL Project , So definitely my question could be naive . Till now I used to create new property in Business Object beside of every DateTime Property , That's because i need to do some processing in my DateTime property and show it in special string format for binding to UI Controls .Like : private DateTime _insertDate; /// /// I have "InertDate" field in my Table on Database /// public DateTime InsertDate { get { return _insertDate; } set { _insertDate = value; } } // Because i need to do some processing I create a readonly string property that pass InsertDate to Utility method and return special string Date public string PInsertDate { get { return Utility.ToSpecialDate(_insertDate); } } My question is I don't know how to do it in LINQ . I did like follow but i get run time error. ToosDataContext db = new ToosDataContext(); var newslist = from p in db.News select new {p.NewsId,p.Title,tarikh =MD.Utility.ToSpecialDate( p.ReleaseDate)}; GridView1.DataSource = newslist; GridView1.DataBind();

    Read the article

  • Hibernate updating records and implementing listeners : getting only required attribute values for event.getOldState()

    - by Narendra
    Hi All, I am using Hibernate 3 as my persistence framework. Below is the sample hbm file I am using. <?xml version="1.0"?> <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd"> <hibernate-mapping> <class name="com.test.User" table="user"> <meta attribute="implements">com.test.dao.interfaces.IEntity</meta> <id name="key" type="long" column="user_key"> <generator class="increment" /> </id> <property name="userName" column="user_name" not-null="true" type="string" /> <property name="password" column="password" not-null="true" type="string" /> <property name="firstName" column="first_name" not-null="true" type="string" /> <property name="lastName" column="last_name" not-null="true" type="string" /> <property name="createdDate" column="created_date" not-null="true" type="timestamp" insert="false" update="false" /> <property name="createdBy" column="created_by" not-null="true" type="string" update="false" /> </class> </hibernate-mapping> I am added a post-update listener. What it will do is if there any updations perfomed on User then it will be invoked and cahnges will be inserted to audit table. Below is the sample implementation for postupdate event. public void onPostUpdate(PostUpdateEvent event) { LogHelper.info(logger, "Begin - onPostUpdate " + event.getEntity().getClass().getSimpleName()); if (!this.checkForAudit(event.getEntity().getClass().getSimpleName())) { // check do we need to audit it. } // Get Attribute Names String[] attrNames = event.getPersister().getEntityMetamodel() .getPropertyNames(); Object[] oldobjectValue = c Object[] newObjectValue = event.getState(); this.auditDetailsEvent(attrNames, oldobjectValue, newObjectValue); LogHelper.info(logger, "End - onPostUpdate"); // return false; } Here is my requirement. event.getPersister().getEntityMetamodel() .getPropertyNames(); or event.getOldState(); or event.getState(); must return attribute names or value which i can update or insert. Is there any way to control the return values of above one's. Pleas help me on this regard. Thanks, Narendra

    Read the article

  • get output of last Process on SSAS cube

    - by Raj More
    I have processed a SSAS cube. After it was done processing, I hit the close button - and then realized that I should have saved the output. I think SSAS stores the processing log as a text or XML file, but I do not know what folder to look into. Can someone direct me to retrieving processing logs?

    Read the article

  • Is there a substitute for blockproc in Matlab?

    - by SetchSen
    I've been using blockproc for processing images blockwise. Unfortunately, blockproc is part of the Image Processing Toolbox, which I don't have on my personal computer. Is there a combination of functions in base Matlab that can substitute for blockproc? My initial guess was to use im2col to transform each block into columns, and then arrayfun to process each column. Then I realized that im2col is also a part of the Image Processing Toolbox, so that doesn't solve my problem.

    Read the article

  • Keypress event on inserted span (jQuery)

    - by Coder
    Hi, I've been researching for a long time, and haven't found a possible solution. The problem I have is that I'm trying to attach an event handler to an span element just inserted. So basically the problem is, when a user performs a particular action that I set (clicking a button by example) I call this function: function AppendSpan() { $('#mydiv').append('<span id="someid" contenteditable="true">Some TExt</span>'); //Then I want to handle the keypress event on the inserted span $('#someid').keypress(function(event){//Do something here}); } The problem is that the keypress event is never triggered on the inserted span, I tried with the click event and it works fine, but not the keypress or keydown,keyup events. I also tried with $('span').live("keypress",function(event){//Do something}); but didn't work. Any suggestions would be appreciated, I need this to work only in FF, so no support for IE required.

    Read the article

  • How To Use ObjectDataSource With Complex Objects and FormView Control

    - by obautista
    I have a complex object. For example a SCHOOL object that contains a collection of PERSON object. How can I use the ObjectDataSource control with a FormView and flatten the complex object? An example display would be to display the school name and comma separate the students on the page. Is this possible? I.E. public string Id { get { return m_id; } set { m_id = value; } } public string SchoolName { get { return m_schoolName; } set { m_schoolName = value; } } public List(Person Students { get { return m_students; } set { m_cast = students; } }

    Read the article

  • Problem processing large data using Applet-Servlet communication

    - by Marquinio
    Hi everyone. I have an Applet that makes a request to a Servlet. On the servlet it's using the PrintWriter to write the response back to Applet: out.println("Field1|Field2|Field3|Field4|Field5......|Field10"); There are about 15000 records, so the out.println() gets executed about 15000 times. Problem is that when the Applet gets the response from Servlet it takes about 15 minutes to process the records. I placed System.out.println's and processing is paused at around 5000, then after 15 minutes it continues processing and then its done. Has anyone faced a similar problem? The servlet takes about 2 seconds to execute. So seems that the browser/Applet is too slow to process the records. Any ideas appreciated. Thanks.

    Read the article

  • Flagging complex properties as Browsable in the compact framework

    - by Rowland Shaw
    I'm working on a compact framework project and whilst most of the properties are fairly straight forward (I.e. mark them as browsable in the xmta file), I'm struggling to get this to work for more complex types - on the full framework, I'd just implement a custom TypeConverter and go from there, but it seems the CF TypeConverter doesn't have any of the type converting methods to override, which has left me a little stuck? It probably should be blindingly obvious but how would I go about supporting design time property support for more complex types (for the sake of argument, assume I can already convert to and from a string, but I'd prefer to keep this strongly typed, rather than just pretend it was a string and parse it both ways. Where should I be looking to achieve this?

    Read the article

  • Printing complex widgets in Qt

    - by Jens
    I have a complex widget with tons of different subwidgets, e.g. subclasses of QLabel. I want to print this widget, but obviously I do not want to print the background, I want to print with differing text colors or have the style of frames slightly modified. As I do not really want to iterate through all subwidgets with a special "print" function, which I would need to attach to all widgets (how to add "print" to a QLabel?), I would like to use paintEvent. If I have a hierarchy MyWidget - derived from - some QWidget, I would like to insert a sublayer MyWidget - MyPrintWidget - some QWidget, where myPrintWidget::paintEvent would check, if the current print is going to the screen (thus call QWidget::paintEvent), else if we are printing to the printer, call some function MyPrintWidget::drawWidget instead. Is this the right way to print-enable a widget? How can I figure out in paintEvent, that I'm printing to a printer instead of the screen? Is there a good example of printing complex widgets?

    Read the article

  • How to set a bean property before executing this f:event listener

    - by user
    How to set a bean property from jsf page before executing this f:event listener: <f:event type="preRenderComponent" listener="bean.method}"/> I tried the below code but it does not set the value to the bean property. <f:event type="preRenderComponent" listener="bean.method}"> <f:setPropertyActionListener target="#{bean.howMany}" value="2"/> </f:event> JSF2.1.6 with PF 3.3 EDIT Any issues with this below code? (This works! but I just want to confirm if there are any issues with this!?) <f:event type="preRenderComponent" listener="#{bean.setHowMany(15)}"/> <f:event type="preRenderComponent" listener="#{bean.method}"/>

    Read the article

  • Sending a variable from a processing page back to the original PHP page

    - by user1228907
    So on a PHP page (page 1) I have some HTML, including : <form action="create_subject.php" method="post" > Which goes to a processing page (page 2) containing MySQL which will be executed if there aren't any errors. If there are (checked by validation on the processing page (page 2)) or aren't, certain variables are set, including this one for if it's successful : if (mysql_affected_rows() == 1){ $success = 1; redirect_to("new_subject.php"); } However, how would I include $success into the URL without putting it in as : redirect_to("new_subject.php?success=1"); I can't do this as I need to do if statements, and it's only PHP on "page 2" so I can't do an if statement inside redirect_to("new_subject.php"); I know I could do ... } else { redirect_to("new_subject.php?success=1"); } But this would seem mundane and non-semantic especially as I have several variables to proccess.

    Read the article

  • Grails - showing page processing/render debug information in development mode

    - by ovokinder
    I've been experimenting with Grails for the past two days and, so far, I'm really happy with it. Coming from Rails, the only thing I've really been missing here is the dev-mode debug information shown after the page has been served. This is what I mean: Processing UsersController#show (for 127.0.0.1 at 2010-06-14 10:28:44) [GET] Parameters: {"id"=>"2"} User Load (0.0ms) SELECT * FROM "users" WHERE ("users"."id" = 2) Rendering template within layouts/users Rendering users/show Completed in 24ms (View: 5, DB: 0) | 200 OK [http://localhost/users/2] Is there any way to get something similar in Grails? I've tried the "debug" plugin but its not very useful as it only shows the total processing time. I know it's not hard too roll something of my own (except for that database stats part), I just wanted to make sure I wasn't unnecessarily reinventing the wheel.

    Read the article

  • Type signature "Maybe a" doesn't like "Just [Event]"

    - by sisif
    I'm still learning Haskell and need help with the type inference please! Using packages SDL and Yampa I get the following type signature from FRP.Yampa.reactimate: (Bool -> IO (DTime, Maybe a)) and I want to use it for: myInput :: Bool -> IO (DTime, Maybe [SDL.Event]) myInput isBlocking = do event <- SDL.pollEvent return (1, Just [event]) ... reactimate myInit myInput myOutput mySF but it says Couldn't match expected type `()' against inferred type `[SDL.Event]' Expected type: IO (DTime, Maybe ()) Inferred type: IO (DTime, Maybe [SDL.Event]) In the second argument of `reactimate', namely `input' In the expression: reactimate initialize input output process I thought Maybe a allows me to use anything, even a SDL.Event list? Why is it expecting Maybe () when the type signature is actually Maybe a? Why does it want an empty tuple, or a function taking no arguments, or what is () supposed to be?

    Read the article

< Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >