Posts

scala - Spray.io - delegate processing to another actor(s) -

I apply a REST service using spray.io frameworks. Such a service should receive some "search" queries, take action on them and return results to the customer. Code which has been discovered in different actor - search, after receiving the query from the user (JSON), I send this query again from my search engine (using the Ask Pattern) but I do not really understand that This is how I should apply the conversation between the spray.io route actor and my SearchActor. I look at many variations here, but which one is more correct and why? Create an example of a search operator at startup and send every request to this actor Create the pool of the search actor actor at the startup and send the request to this pool class = "post-text" itemprop = "text"> You have not been forced to use the pattern to ask In fact, This will create a thread for each of your requests and probably is not what you want . I recommend that you use a tell instead yo...

android - Open Chrome App with URL -

Is there a way to open Chrome apps from the default Android browser on Android? I'm able to open the app, but it does not redirect the user to the correct page. This is what I tried: & lt; A href = "googlechrome: //www.toovia.com" & gt; I see that I may have to make an intention URL, but I was hoping that there is a much easier way than that. This is a web page and there is no web view involved in it. Yes, but if it is not installed on the system you will participate in the ActivityNotFound exception if it is not available , Then you should launch via the normal browser: string URL = "http: // mysuperwebsite"; Try {intent i = new intent ("android.intent.action.MAIN"); I.setComponent (ComponentName.unflattenFromString ("com.android.chrome/com.android.chrome.Main")); I.addCategory ("android.intent.category.LAUNCHER"); I.setData (Uri.parse (url)); startActivity (i); } Catch (ActivityNotFoundException E) {// ...

mobile - Loading animated interactive content in Sencha Touch 2 -

I have an animated interactive quiz on a URL that I want to load in my app . The URL is http: //some-link/story.html . Its an HTML file though content is animated and interactive. But when I load it, then nothing, but only appears blank. I'm testing with Android using Cordova on the device. 4.3 I'm using it to load the animation Ext.define ('View myApp: Mapple, extension:' extension ', config: {id:' MyPanel ', itemId:' MyPanel ', scrollable: right, listeners: [{fn:' OnMyPanelActivate ', Event:' Active '}]}, Activate OnMyPanel: Function (New Activitum, Container, Old Active Item, eOpts) {Ext.Ajax.request ({// Local path of your HTML file url: 'http: //some-link/story.html', success: function (response) {Ext.getCmp ('MyPanel'). SetHtml (response.responseText);} , Failure: Function (Re: ) {Var text = response.responseText; Ext.Msg.alert ('error', text, Ext.emptyFn);}}}}}}); Second it ext Try to load i...

java - ReentrantReadWriteLock and synchronized blocks -

If I have ReentrantReadWriteLock , and I can use it as a lock in the synchronized block Do other threads still release your locks? For example: ReentrantReadWriteLock lock = new ReentrantReadWriteLock (true); Public Zero doSomething () {synchronize (lock) {lock.readLock (). Lock (); // do stuff lock.readLock () Unlock (); }} If I call doSomething () and another thread keeps the already read lock, does it continue to read the thread read? Can do? When I call doSomething () , then I will synchronize on ReentrantReadWriteLock and then try to get the lock to be read. Since there is a pre-read lock, I will block that lock until it is released. I'm curious to know whether reading lock can be released since being synchronized on the lock. Syncing on a REINrent Redirect Lock object seems like an incredibly bad idea. Locking completely free lock. First of all, it locks the mute x built in each object (in this case, the restartreddrytalk object), and then it locks ...

active directory - Differences in calling CSVDE from Powershell vs Command Prompt -

Can anyone explain why calling a CSVDE utility from an advanced Windows Command Prompt, a vertical powerhole console? The problem I have is that I can successfully export from Active Directory via the command prompt method, but PowerShell returns an authentication error, "Simple Tie Back" Invalid Credential '. For both here The command to be used is edited for sensitive pieces: c: \ csvde.exe -s domain.company.org -f ExportFile.csv -l "The name given above, SP, IPhone, Title, Dept., Company, Physical DeliveryOfficeName, Mail "-D" OU = ABC Group, OU = ABC User, DC = Domain Name, DC = ORG "- A User Distant Encant Password Running with the privileges of both session administrators I am a powerless newbie, and for my life, I can not understand it. Thank you! I can see two possible issues. The first thing is that it separates your username and password. Or as Adi Inbar has suggested: You have some special characters that are causing probl...

android - Alignment layout at the bottom with listview -

I have a list view and a linerlayout (bottom bar) at the bottom. When the list view expands, I can not scroll properly because the bottom linear layout has seen the meeting. I do not understand where the problem is ... I want to separate the bottom strip from the list view. This is my layout (possibly, can you customize this layout?): & Lt; / RelativeLayout & gt; & Lt; LinearLayout Android: layout_width = "match_parent" Android: layout_height = "50dp" Android: Orientation = "Horizontal" Android: layout_gravity = "bottom" style = "@ Android: Style / Widget.Holo.Light.ActionBar.Solid" & gt; & Lt; Spinner Android: Android: Android: Android: Layout_Wind = "wrap_ content" Android: layout_heat = "wrap-content" Android: layout_weight = "1" Android: layout_gravity = "center_weight" Android: layout_margin = "8dp" & gt; & Lt; Android: layout_height = "w...

knockout.js - Wiring Bootstrap-switch to knockout observable -

I'm looking at this example to wire the occurrence of a bootstrap button. I am having trouble with the fact that how do I add it to some other knockout. I have a noticeable self.IsAggregate = ko.observable (modeldata.SelectedItem.Aggregate); There is a default value on the load, I'm trying to wire it in the switch. I can not even understand the syntax in the belt. How are they defining a : for observation and not a = ? When I try this, a syntax throws error. Eventually I am trying to replace the IsAggregate with compulsive // Registration switch $ ("[name = 'toggle list']"). Bootstrap switch (); $ ("[Name = 'toggleAggregate']") bootstrapSwitch () .; Var viewloadel = function (modal data) {var itself = this; Self. To = to Spectacular (true), self Selected = K. orssabel (ModelData selected) list; Igragget = to.SourceWeble (ModelData selected item. Argentina); Self-enabled. = HorseBel (Mod.Data selected item. Enabled)...