Search Results

Search found 14236 results on 570 pages for 'times square'.

Page 217/570 | < Previous Page | 213 214 215 216 217 218 219 220 221 222 223 224  | Next Page >

  • Multithreaded java cache for objects that are heavy to create ?

    - by krosenvold
    I need a cache some objects with fairly heavy creation times, and I need exactly-once creation semantics. It should be possible to create objects for different CacheKeys concurrently. I think I need something that (under the hood) does something like this: ConcurrentHashMap<CacheKey, Future<HeavyObject>> Are there any existing open-source implementations of this that I can re-use ?

    Read the article

  • ruby enclose selected whole words in brackets

    - by astropanic
    @string = "Sometimes some stupid people say some stupid words" @string.enclose_in_brackets("some") # => "Sometimes {some} stupid people say {some} stupid words" How should the method enclose_in_brackets look ? Please keep in mind, I want only enclose whole words, (I don't want "{Some}times {some} stupid....", the "sometimes" word should be left unchanged

    Read the article

  • How can I set time limit on get_file_contents in PHP?

    - by Jagira
    Hello, At times the get_file_contents takes too long and that hangs the entire script. Is there any way of setting a time out limit on get_file_contents, without modifying the maximum execution time of the script? Edit: Its taking long because the file does not exist. I am getting "failed to open stream: HTTP request failed!" error. But it takes forever.

    Read the article

  • Neural Network 0 vs -1

    - by Louis
    I have seen a few times people using -1 as opposed to 0 when working with neural networks for the input data. How is this better and does it effect any of the mathematics to implement it? Edit: Using feedforward and back prop Edit 2: I gave it a go but the network stopped learning so I assume the maths would have to change somewhere?

    Read the article

  • Chrome not displaying a div

    - by Kyle Sevenoaks
    Click here to see a simple example of what I want. It's really easy, but for some reason Google won't display the "subTotalCaption2" div. It's part of a foreach loop, if needed I can add other codes. There is nothing else in the rest of the css to mess with this, I have checked about 10 times. See it live at euroworker.no/order (add items to basket) In FF and Chrome. Thanks.

    Read the article

  • Limiting XML read to 5 records

    - by Jean
    Hello, I have a xml file with 100 records, but I want it to limit it to just 5 records for ($i=0;$i<=5;$i++) { foreach($xml-entry as $result){ if ($result->updated == $result->published) { } } } When I put in the above code, it display one record 5 times. Thanks Jean

    Read the article

  • SEO Friendly URLs where the phrase used may change in Rails

    - by Newy
    Say I have http://www.mysite.com/I-Like-Cheeseburgers and I want that to point to Item with id 3. Sometime later, I change the name of the item, and now its http://www.mysite.com/I-Like-Hamburgers (and perhaps many more times). I want all these URLs to remain pointing to Item 3. Is it efficient to simply keep a table of [strings,item_ids] and do a lookup on this? Is there a better way?

    Read the article

  • Write string to fixed-length byte array in C#

    - by toasteroven
    somehow couldn't find this with a google search, but I feel like it has to be simple...I need to convert a string to a fixed-length byte array, e.g. write "asdf" to a byte[20] array. the data is being sent over the network to a c++ app that expects a fixed-length field, and it works fine if I use a BinaryWriter and write the characters one by one, and pad it by writing '\0' an appropriate number of times. is there a more appropriate way to do this?

    Read the article

  • How to "grep" out specific lline ranges of a file

    - by Mike
    There are often times I'll grep -l whatev file to find what I'm looking for. Say the output is 1234: whatev 1 5555: whatev 2 6643: whatev 3 If I want to then just extract the lines between 1234 and 5555, is there a tool to do that? For static files I have a script that does wc -l of the file and then does the math to split it out with tail & head but that doesn't work out so well with log files that are constantly being written to.

    Read the article

  • Can you view XAML as "regular" .net code (c#\vb.net)?

    - by cody
    There are times when I find some example XAML that I want\need to do in code (c#\vb.net). I assume at some point the XAML becomes code, or at least IL. So my questions: Am I correct in assuming that XAML is converted to IL? (or if not IL what does it become?) If the above is correct, when does XAML become IL (or whatever it becomes)? Is there some way to see the XAML in as "code" Thanks.

    Read the article

  • MS SQL tuning tools for finding overload

    - by SkyFox
    I use MS SQL server as a DBMS for my very big corporate DB (with different financial data). And some times my system go down. I don't understand why. What programs/tools I can use for finding process/program/thread, that overload my SQL-server? Thanks for all answers!

    Read the article

  • Java ActionListener buttonPress() restriction

    - by Extinct23
    Is there a way to restrict this button to only being impressed once? The reason I ask is because for some reasons every time the button is pressed it disrupts the rest of my code. So in effort to save a massive amount of time debugging, it would be much easier to just somehow restrict the number of times it can be pressed. Thanks in advance. ActionListener pushButton = new buttonPress(); start.addActionListener(pushButton);

    Read the article

  • Adding an additional click event to every element (JavaScript / jQuery)

    - by Gausie
    I'm developing a touchscreen application that, aside from everything else, records the amount of times the screen is used so that the user can be reminded to clean the screen after a predefined number of clicks. I've got the click functions written nicely, all I need now is make sure the function is called on a click. I imagine $('*').click(function() { //do something }); would accomplish my goal, but is that the best way? Also, would that overwrite other click functions assigned to the elements?

    Read the article

  • Can I Force A ASP.Net Website to Show Time in A Specific Time Zone?

    - by KevDog
    I have a client request that all times be displayed in Pacific Time Zone, regardless of client settings. I'd like to avoid a scenario where I have to call a function for every time display and instead have a single point where I can make the switch. I'm thinking a custom culture might do the trick, but I wanted to ask before I set off down a potentially blind alley (or miss something trivially easy).

    Read the article

  • Using Int32 or what you need

    - by Sir Psycho
    Should you use Int32 in places where you know the value is not going to be higher than 32,767? I'd like to keep memory down, hoever, using casts everywhere just to perform simple arithmetic is getting annoying. short a = 1; short result = a + 1; // Error short result = (short)(a + 1); // works but looks ugly when does lots of times What would be better for overall application performance?

    Read the article

  • When running UPDATE ... datetime = NOW(); will all rows updated have the same date/time?

    - by Darryl Hein
    When you run something similar to: UPDATE table SET datetime = NOW(); on a table with 1 000 000 000 records and the query takes 10 seconds to run, will all the rows have the exact same time (minutes and seconds) or will they have different times? In other words, will the time be when the query started or when each row is updated? I'm running MySQL, but I'm thinking this applies to all dbs.

    Read the article

  • Is there a better way to format this date string

    - by Mark Breen
    Hello is there are better way to structure this line of code, as you can see, I am changing the format of a string that contains a date. lblCourseStartDate.Text = String.Format("{0:D}", DateTime.Parse(CourseStartDate)); I just found it untidy that I am converting twice or three times to get the format I want. Thanks

    Read the article

< Previous Page | 213 214 215 216 217 218 219 220 221 222 223 224  | Next Page >