Search Results

Search found 1223 results on 49 pages for 'don stewart'.

Page 12/49 | < Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >

  • Why do software engineers hate writing documentation?

    - by Stewart Johnson
    I ask because I quite enjoy it! I'm talking about design documentation and implementation notes (NOT user manuals), which are non-existent in most of the codebases I've been handed. I can understand why a developer wouldn't want to write requirements (that's the analyst's job) or the user documentation (that's a technical writer's job) but I don't get why developers hate writing design docs. I don't think I would feel as if I'd finished the job if I only wrote the code and walked away -- mainly because when I've been introduced to code-only situations I've seen how hard it is to figure out what's been done and what the software does. I would hate for people to suffer the same situation when inheriting my code. What makes you loath writing supporting documentation for your code?

    Read the article

  • How can I prevent my Android app/service from being "killed" from a task manager?

    - by Don
    It is very important that my service stay running until someone with a password stops the service from my UI screen. My app runs great but it is designed to be turned on/off by parents (with a password) on their kids phones. I have managed to make everything work but the problem I'm having is that if the kid uses a task manager to kill my service then my app is useless. I would be grateful to anyone who knows a way to either 1) monitor the service and start it back up automatically if its "killed" or 2) prevent someone from being able to kill it except from the activity (administration screen) that launched the service. Or both? I'm sorry if I'm not very clear in describing the problem, I'm a beginner. I've made great progress so far but I am stuck at this last hurdle.

    Read the article

  • Seeking STL-aware c++filt

    - by Don Wakefield
    In my development environment, I'm compiling a code base using GNU C++ 3.4.6. Code is under development, and unfortunately crashes now and then. It's nice to be able to run the traceback through a demangler, and I use c++filt 3.4. The problem comes when functions have a number of STL parameters. Consider My_callback::operator()( Status&, std::set<std::string> const&, std::vector<My_parameter*> const&, My_attribute_set const&, std::vector<My_parameter_base*> const&, std::vector<My_parameter> const&, std::set<std::string> const& ) { // ... } When this function is in the traceback, the mangled output on my platform is: (_ZN30My_callbackclER11StatusRKSt3setISsSt4lessISsESaISsEERKSt6vectorIP13My_parameterSaISB_EERK17My_attribute_setRKS9_IP18My_parameter_baseSaISK_EERKS9_ISA_SaISA_EES8_+0x76a) [0x13ffdaa] c++filt kindly demangles it to (My_callback::operator()(Status&, std::set<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::less<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, std::vector<My_parameter*, std::allocator<My_parameter*> > const&, My_attribute_set const&, std::vector<My_parameter_base*, std::allocator<My_parameter_base*> > const&, std::vector<My_parameter, std::allocator<My_parameter> > const&, std::set<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::less<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&)+0x76a) [0x13ffdaa] This is the same problem as compiler errors encountered when using templates. However, the STL is a fairly regular and recognizable package of templates. So what I'm hoping is that someone out there has created an enhanced version of c++filt which would dump something closer to the original function signature. Any hints?

    Read the article

  • Recovering transaction log from corrupt SQL database

    - by Don Kirkham
    We have a database that is backed up weekly in simple mode. Yesterday, we had a crc error corrupt the mdf file and we were unable to save it. I restored the backup from last week, but now we have a gap from the time of the backup to the time of the restore. Since I have the ldf file from that database, is there any way to "replay" that transaction log to fill in the gap? I have tried reattaching the ldf file to the recovered mdf file, but SQL will not allow me to do that. (It just creates a new ldf file with a different name when I reattach the database.) Any ideas would help. This is a lot of data to lose and although it is not critical data, I'd like to get it back (as well as learn as well as learn how to do it.)

    Read the article

  • Select a random row from table, but with odds?

    - by Don
    I have a table that describes a variety of objects in my system (ie. umbrella, boots, satchel, whatever). Each one of these objects needs to have a distinct prevalence or incidence. For example, the umbrella is rarer than the boots. Based on those factors, I need to randomly select a single object (including a blank or 'no object found') based on that incidence value. Yikes. Make sense?

    Read the article

  • Python: re-initialize a function's default value for subsequent calls to the function.

    - by Peter Stewart
    I have a function that calls itself to increment and decrement a stack. I need to call it a number of times, and I'd like it to work the same way in subsequent calls but, as expected, it doesn't re-use the default value. I've read that this is a newbie trap and I've seen suggested solutions, but I haven't been able to make any solution work. It would be nice to be able to "fun.reset" def a(x, stack = [None]): print x,' ', stack if x > 5: temp = stack.pop() if x <=5: stack.append(1) if stack == []: return a(x + 1) print a(0) print a(2) #second call print a(3) #third call I expected this to work, but it doesn't. print a(0, [None]) print a(2, [None]) #second call print a(3, [None]) #third call Can I reset the function to it's initial state? Any help would be appreciated.

    Read the article

  • Can I add a condition to CakePHP's update statement?

    - by Don Kirkby
    Since there doesn't seem to be any support for optimistic locking in CakePHP, I'm taking a stab at building a behaviour that implements it. After a little research into behaviours, I think I could run a query in the beforeSave event to check that the version field hasn't changed. However, I'd rather implement the check by changing the update statement's WHERE clause from WHERE id = ? to WHERE id = ? and version = ? This way I don't have to worry about other requests changing the database record between the time I read the version and the time I execute the update. It also means I can do one database call instead of two. I can see that the DboSource.update() method supports conditions, but Model.save() never passes any conditions to it. It seems like I have a couple of options: Do the check in beforeSave() and live with the fact that it's not bulletproof. Hack my local copy of CakePHP to check for a conditions key in the options array of Model.save() and pass it along to the DboSource.update() method. Right now, I'm leaning in favour of the second option, but that means I can't share my behaviour with other users unless they apply my hack to their framework. Have I missed an easier option?

    Read the article

  • How to define specific permissions ?

    - by Don Carnage
    Hi, on the project i'm working we have a site (the front office) which is accessible by anonymous users, and a subsite (the back office) which access is restricted. In the back office, i want to restrict the access of one specific page (e.g, /Pages/specificpage.aspx) to only users who are members of a certain group. How can i do that ? Thanks.

    Read the article

  • How is includegraphic interfering with tabular?

    - by Charles Stewart
    I'm editing a text provided by my client as a LyX file that includes graphics and other files that I don't have. I've "commented out" the graphics by putting in a custom preamble that substitutes the file-loading definitions with macros that just quote their arguments. However, the \includegraphic macro throws up an error in the two tabular environments where it is used, complaining that \endfirsthead was never defined. What is this macro, and why is it interfering with mine? The preamble: \usepackage{natbib} \def\fileloc{/some/path/stylefile} \newif\iftextproof \IfFileExists\alifefileloc\textproofalse\textprooftrue \iftextproof \usepackage{./stylefile} %natbib subst: \renewcommand\cite[1]{{\tt #1}} %suppress graphics includes: \def\quotearg#1{\expandafter\string\csname #1\endcsname} \newcommand\gobbleIG[2][*void*]{{\footnotesize \quotearg{#2}}} \newcommand\gobbleSF[2][*unnamed*]{{\bf #1}} \let\includegraphics=\gobbleIG \let\subfigure=\gobbleSF \else \usepackage\fileloc \fi

    Read the article

  • Building a complete online payment gateway like Paypal

    - by John Stewart
    So this question isn't about integrating an existing payment gateway into my site. This is more of a architectural question. I want to build a system similar to Paypal. Now I understand that Paypal offers a lot of features under the roof and I can't implement all of them at once. I want to implement the core functionality of Paypal and other such services. So my question is (rather discussion is) around how would one go about building such a system. Some points to discuss: Handle payments through existing banks. I am guessing that I would need access to local bank protocols to get this. Allow users to securely store and process their payments How does Paypal handle the transactions? Thoughts?

    Read the article

  • Can I make DataGridView.EndEdit trigger the CellValidating event?

    - by Don Kirkby
    I'm using a DataGridView in my WinForms application. My main objective is to make the Enter key not move to the next row in the grid. I still want the enter key to validate and end edit mode. I found this FAQ entry and subclassed DataGridView to override ProcessDialogKey(). If the key pressed is Enter, I call EndEdit(), otherwise I call base.ProcessDialogKey(). It works great, except the CellValidating event isn't fired. Currently, I'm just manually calling my validation logic before I call EndEdit, but it seems like I'm missing something. I guess I could call OnCellValidating, but then I'd be worried I'm missing some other event. What I really want is some flavour of EndEdit() that behaves just like pressing enter on the last row of a grid with adding disabled.

    Read the article

  • How to access SharePoint web part properties?

    - by shannon.stewart
    I have created a feature for SharePoint 2007 that has a web part. I have added a custom property to the web part like so: [Personalizable(PersonalizationScope.Shared)] [WebBrowsable(true)] [Category("My Custom Properties")] [WebDisplayName("ServiceURL")] [WebDescription("The URL for the Wcf service")] public string ServiceURL { get; set; } Along with this web part, I've added a custom page that the web part will have a link to. I would like to reference the web part property from the custom page, but I don't know where these properties are stored. I've tried to access it using the code below, but both property collections don't have any properties stored. SPFeaturePropertyCollection spProperties = SPContext.Current.Site.Features[this.FeatureGuid].Properties; or SPFeaturePropertyCollection spProperties = SPContext.Current.Site.Features[this.FeatureGuid].Definition.Properties; My question is how can I get a reference to the web part property from other pages?

    Read the article

  • How can I compare Core Data models?

    - by Don
    I noticed while doing system testing that a feature of our app had been removed. It looks like at some point, an older version of a file was checked into SVN that was missing a property. This specific file was generated from the Core Data model, and sure enough, the latest version of the model in SVN is missing the same attribute. I need to find out if any other attributes are missing, or if anything else in the model changed. However, the elements file in the .xcodedatamodel folder appears to binary and I can't compare the revisions. Is there a way to find the differences between two Core Data models in SVN? Barring that, what would be the best way to accomplish this task?

    Read the article

  • replacing toString using Groovy metaprogramming

    - by Don
    In the following Groovy snippet, I attempt to replace both the hashCode and toString methods String.metaClass.toString = {-> "override" } String.metaClass.hashCode = {-> 22 } But when I test it out, only the replacement of hashCode works String s = "foo" println s.hashCode() // prints 22 println s.toString() // prints "foo" Is toString somehow a special case (possibly for security reasons)?

    Read the article

  • Ensuring a divs content has changed over time in Selenium

    - by Stewart Robinson
    I have a div that contains a slideshow. ( http://film.robinhoodtax.org/issues/education ) I am using Selenium to test it. So far I have been using the HTML/Selenium script below to validate that the slideshow is actually working. But my assertEval is failing. How can I correctly detect the slideshow and make sure it is moving?. You can see I've approached this by storing the HTML and waiting then trying again but it isn't working. <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head profile="http://selenium-ide.openqa.org/profiles/test-case"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <link rel="selenium.base" href="" /> <title>New Test</title> </head> <body> <table cellpadding="1" cellspacing="1" border="1"> <thead> <tr><td rowspan="1" colspan="3">New Test</td></tr> </thead><tbody> <tr> <td>open</td> <td>/issues/education</td> <td></td> </tr> <tr> <td>waitForPageToLoad</td> <td></td> <td></td> </tr> <tr> <td>assertElementPresent</td> <td>css=div[id='views-nivo-slider-ImagesGallery-block_1']</td> <td></td> </tr> <tr> <td>storeHtmlSource</td> <td>css=div[id='views-nivo-slider-ImagesGallery-block_1']</td> <td>first</td> </tr> <tr> <td>pause</td> <td>3000</td> <td></td> </tr> <tr> <td>storeHtmlSource</td> <td>css=div[id='views-nivo-slider-ImagesGallery-block_1']</td> <td>second</td> </tr> <tr> <td>assertEval</td> <td>${first} == ${second}</td> <td>second</td> </tr> </tbody></table> </body> </html>

    Read the article

  • Apache mod-rewrite for shorter urls

    - by Don
    Is it possible do do something like this with mod-rewrite? Current url: www.example.com/Departments/dynamicPage.php?DeptID=10&DeptName=HR to set up a rewrite so: www.example.com/hr could redirect to the above (with the arguments)? I know I could create an "hr" folder on the root level and put in an html page with a meta refresh, but I hate the extra clutter. I don't think a .htaccess 301 is possible, but please correct me if I'm wrong. I'm looking for an elegant solution that can be added to for future instances.

    Read the article

  • OS X: Terminal output of javac is garbled.

    - by Don Werve
    I've got my computer set up in Japanese (hey, it's good language practice), and everything is all fine and dandy... except javac. It displays localized error messages out to the console, but they're in Shift-JIS, not UTF8: $ javac this-file-doesnt-exist.java javac: ?t?@?C??????????????: this-file-doesnt-exist.java ?g????: javac <options> <source files> ?g?p?\??I?v?V?????~??X?g?????A-help ???g?p???? If I pipe the output through nkf -w, it's readable, but that's not really much of a solution: $ javac this-file-doesnt-exist.java 2>&1 | nkf -w javac: ????????????: this-file-doesnt-exist.java ???: javac <options> <source files> ????????????????????-help ?????? Everything else works fine (with UTF8) from the command-line; I can type filenames in Japanese, tab-completion works fine, vi can edit UTF-8 files, etc. Although java itself spits out all its messages in English (which is fine). Here's the relevant bits of my environment: LC_CTYPE=UTF-8 LANG=ja_JP.UTF-8 From what it looks like, javac isn't picking up the encoding properly, and java isn't picking up the language at all. I've tried -Dfile.encoding=utf8 as well, but that does nada, and documentation on the localization of the JVM toolchain is pretty nonexistent, at least from Google.

    Read the article

  • I need to speed up a function. Should I use cython, ctypes, or something else?

    - by Peter Stewart
    I'm having a lot of fun learning Python by writing a genetic programming type of application. I've had some great advice from Torsten Marek, Paul Hankin and Alex Martelli on this site. The program has 4 main functions: generate (randomly) an expression tree. evaluate the fitness of the tree crossbreed mutate As all of generate, crossbreed and mutate call 'evaluate the fitness'. it is the busiest function and is the primary bottleneck speedwise. As is the nature of genetic algorithms, it has to search an immense solution space so the faster the better. I want to speed up each of these functions. I'll start with the fitness evaluator. My question is what is the best way to do this. I've been looking into cython, ctypes and 'linking and embedding'. They are all new to me and quite beyond me at the moment but I look forward to learning one and eventually all of them. The 'fitness function' needs to compare the value of the expression tree to the value of the target expression. So it will consist of a postfix evaluator which will read the tree in a postfix order. I have all the code in python. I need advice on which I should learn and use now: cython, ctypes or linking and embedding. Thank you.

    Read the article

  • Paypal Payflow pro library

    - by John Stewart
    I already have an express checkout integrated with my Codeigniter application. Now I want to integrate seamless paypal where I collect the CC information and pass it to Paypal (via backend) and once everything is approved, my application shows that to the user. All this with out ever going to Paypal's website. I know that Paypal gives a bunch of sample code but they have so many different products that advertise to do the same thing. Is there any wrapper library in PHP that I can use for handling all this? What sort of design decision is involved in migrating to such system? Would I need SSL certificates for this?

    Read the article

< Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >