Posts

java - Gradle dependencies: compile project by relative path -

Is it possible to specify a dependency on another gradeal project in the granular (in android studios) outside the current project limits? For example, with a relative path like this: dependence {collection project ('../../ stdlib / dagger'}} MyApp (path / user / foo / workspace / mypad) The app (Path / User / Foo / Workspace / MyPass / App) And I have an Android Library Project with 3 subdomules: stdlib (path is / user / foo / Utilities (Path / User / Foo / Workspace / Stadlib / Utilis) http (Path / User / Foo / Workspace / Stadlib / HT) / Li> What I have to do is compile the Dagger, Util, http module in the MyApp project. The Stidelib Library module under heavy development And MyApp will grow in the form of Growth, so I do not want to push them into a Mewen repository. I am a little change. is likely to add another Gredle projects in some way? I will push the study library into the Maven repository after the source is in search of a temp...

javascript - geocoder.geocode function does not work -

Hi, I want to land down the place I entered. But it seems that the geocoder.geocode function does not work here it is part of the JavaScript $ ('#InputButtonGeocode'). Click (function () {var sAddress = document.getElementById ('inputTextAddress') .value; geocoder.geocode ({'address': sAddress}, function (result, status) {if (position == google.maps.GeocoderStatus .oK) {map.setCenter (Results [0] .geometry.location); Var Marker = New google.maps.Marker ({Map: Map, Status: Results [0] .geometry.location});} and {Warning} ("The geocode was not successful for the following reason:" + status); This should be a simple problem, but I can not find this problem That is JSFDL link. Please help me Thanks, Good things. It does not seem that your initial function is ever going and therefore Your geographic object can never be created, and this API is not compatible with the Google Maps Embed (iframe) API. For example, you can see that they us...

javascript - Why is my embedded ruby json string encoded with html entities when parsed in the view? -

I have taken a rail operation that requests a GET for the service and then replies to the answer @job_data. The code works fine in retrieving the response, and I've verified that the Jason object looks correct. def show @ url = URI.parse (@@ jobs_base_url + "/" + params [: ID] + "? TestMode = true") req = Net :: HTTP :: Get New (@ url.to_s) res = Net :: HTTP.start (@ url.host, @ url.port) {| Http | Http: request (req)} @job_data = HTMLEntities.new.decode res.body end However, I have to javascript a bit to manipulate DOM elements using this json object I am trying. I am trying to incorporate the script into HTML to do something basic with the JSN object, but it may not seem to be correctly passed: & lt; Script type = "text / javascript" charset = "UTF-8" & gt; $ (Function () {var $ data = & lt;% = @ job_data%> $ ('# jobable') .andend ($ data.Id); when I debug I see that all the entities in the string are ...

php - Problems with preg_match -

I am using preg_match as a way of validating input on a form. Specifically, I am trying to validate the input of currency I is the function: if (preg_match ("/ ^ \ $ (((\ d {1,3} ,) + \ D {3}) | \ d +) \. \ D {2} $ / i ", $ inString)) {back true; } And {return false; } I can get it to work on all this. I return false, irrespective of what I feed it (including legal stars). I'm sure I'm doing something clearly wrong, but I can not see it. You know how it is ... Anyone have any suggestions? Something like this: $ inString = '1550.50'; If (preg_match ("/ \ b \ d {1,3} (?:??? \ D {3}) * (?: \. \ D {2})? \ B /", $ inString)) {echo "truth"; } Else {echo "wrong"; } Explanation: \ b # claim the word limit \ d {1,3} # 1-3 digits (?: # After this group ...,? # An optional comma \ d {3} # exactly three digits) * # ... in any number (?: # After this group ... \. # A literal dot \ d {2} # exactly two digits)? # ... ...

ios - Core Data UITableView, temporarily deleting cell (obj-c) -

I'm populating my table with core data objects and I'm trying to implement some delete functionality. Although I am planning to add shake to the undo, so I do not want to save the managed object reference immediately. My problem is that I am defining the number of cells with the _entity.items.count that does not change until I save the managed object context. So in short, is I going to keep a counter that I add and subtract every time that the user removes or adds an item again? (Do I want to reduce it by counting) or is there an alternative (preferably cleaner) method to deal with this problem? Thanks guys.

ios - UITableView - Controlling or preventing the delete for a specific row in a section -

I am trying to stop the deletion for each last line in each section of my UITableView control. I wrote code that has been working so far. Is there a way to prevent the delete button from appearing in a specific line in a specific section when editing the UITWV mode? Table view: (View UITableView *) View Comment tab: (UITableViewCellEditingStyle) ROATI and Appet for editing style: : (NSIndexPath *) indexPath {NSInteger section = indexPath.section; NSInteger Line = indexPath.row; // If the table view is asking for a command command ... if (edit type == UITableViewCellEditingStyleDelete) {// stop the removal of the last line length = [[[MyItemStore SharedStore] getItemsForGivenSection: section] count] ; // Prevent the last line from being deleted (line == length) {return; } NSArray * items = [[MyItemStore SharedStore] getItemsForGivenSection: section]; MyItem * item = item [row]; [[MyEstmestore ShareStore] removedEstormation: Item section: section]; // Also delete that line f...

ios - linking to third-party static library: "file was built for archive which is not the architecture being linked (i386)" -

I am trying to use a third party open source C ++ static library. I downloaded the archive from the project's web site, run ./configuration - disabled-shared , then create , test , and install . (I am a UNIX novice, so it was following the instructions given on the project's web site.) In the encode, I clicked under the link from the lib folder. Added include folder in the binary, header search path with libraries, and added the -ObjC to another linker flag (although I do not think since the library One important is C ++) When I try to build a project, I get several warnings like ld: warning: file / user / & Lt; My name & gt; / Dropbox / Computing / COIN -OR / Cbc-2.8.10 / lib / libOsiCbc.a, the file was created for archiving which is not related to architecture (i386): / user / & lt; My name & gt; / Dropbox / Computing / COIN-OR / Cbc- 2.8.10 / lib / libOsiCbc.a and many errors such as Undefined symbols for architecture I386: Referenc...