Search Results

Search found 5483 results on 220 pages for 'logic artist'.

Page 3/220 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Modelling Business Logic with NON-Techies

    - by cbmeeks
    The setup: Winform/ASP.NET MVC projects. Learning NHibernate SQL-Server driven apps I work with clients that have no idea how to model an application. That's what I'm for. However, we have lots of conflicts with validation, mis-understandings, etc. For example, the client will ask for an order entry screen. The screen should require a "product". That's fine and dandy. However, the client didn't know to tell me that the user can't order a product of "Class A" unless it's Tuesday. Or, they need a time entry screen. 2 days before it's rolled into production, they casually forgot to mention that certain activities are only valid for certain situations. These situations being a week of coding. That's of course, some crude examples (not by much!). But the problem is getting these non-technical clients to layout their business logic. They somehow didn't realize that the "Class A" problem would come up two weeks later, etc. I'm all for agile programming but is there an easy way to somehow make business logic like this extremely easy to implement and change on almost a daily basis? I of course am splitting the project into hopefully intelligent pieces, using NHibernate, etc. But making this BI logic so dynamic is really making it hard to project timelines, etc. Any suggestions? I know there will never be a perfect client (or a perfect provider) but how do you guys deal with the constant mis-understandings? Thanks.

    Read the article

  • Separation of presentation and business logic in PHP

    - by Markus Ossi
    I am programming my first real PHP website and am wondering how to make my code more readable to myself. The reference book I am using is PHP and MySQL Web Development 4th ed. The aforementioned book gives three approaches to separating logic and content: include files function or class API template system I haven't chosen any of these yet, as wrapping my brains around these concepts is taking some time. However, my code has become some hybrid of the first two as I am just copy-pasting away here and modifying as I go. On presentation side, all of my pages have these common elements: header, top navigation, sidebar navigation, content, right sidebar and footer. The function-based examples in the book suggest that I could have these display functions that handle all the presentation example. So, my page code will be like this: display_header(); display_navigation(); display_content(); display_footer(); However, I don't like this because the examples in the book have these print statements with HTML and PHP mixed up like this: echo "<tr bgcolor=\"".$color."\"><td><a href=\"".$url."\">" ... I would rather like to have HTML with some PHP in the middle, not the other way round. I am thinking of making my pages so that at the beginning of my page, I will fetch all the data from database and put it in arrays. I will also get the data for variables. If there are any errors in any of these processes, I will put them into error strings. Then, at the HTML code, I will loop through these arrays using foreach and display the content. In some cases, there will be some variables that will be shown. If there is an error variable that is set, I will display that at the proper position. (As a side note: The thing I do not understand is that in most example code, if some database query or whatnot gives an error, there is always: else echo 'Error'; This baffles me, because when the example code gives an error, it is sometimes echoed out even before the HTML has started...) For people who have used ASP.NET, I have gotten somewhat used to the code-behind files and lblError and I am trying to do something similar here. The thing I haven't figured out is how could I do this "do logic first, then presentation" thing so that I would not have to replicate for example the navigation logic and navigation presentation in all of the pages. Should I do some include files or could I use functions here but a little bit differently? Are there any good articles where these "styles" of separating presentation and logic are explained a little bit more thoroughly. The book I have only has one paragraph about this stuff. What I am thinking is that I am talking about some concepts or ways of doing PHP programming here, but I just don't know the terms for them yet. I know this isn't a straight forward question, I just need some help in organizing my thoughts.

    Read the article

  • How to deal with elimination of duplicate logic vs. cost of complexity increase?

    - by Gabriel
    I just wrote some code that is very representative of a recurring theme (in my coding world lately): repeated logic leads to an instinct to eliminate duplication which results in something that is more complex the tradeoff seems wrong to me (the examples of the negative side aren't worth posting - but this is probably the 20th console utility I've written in the past 12 months). I'm curious if I'm missing some techniques or if this is really just on of those "experience tells you when to do what" type of issues. Here's the code... I'm tempted to leave it as is, even though there will be about 20 of those if-blocks when I'm done. static void Main(string[] sargs) { try { var urls = new DirectTrackRestUrls(); var restCall = new DirectTrackRestCall(); var logger = new ConsoleLogger(); Args args = (Args)Enum.Parse(typeof(Args), string.Join(",", sargs)); if (args.HasFlag(Args.Campaigns)) { var getter = new ResourceGetter(logger, urls.ListAdvertisers, restCall); restCall.UriVariables.Add("access_id", 1); getter.GotResource += new ResourceGetter.GotResourceEventHandler(getter_GotResource); getter.GetResources(); SaveResources(); } if (args.HasFlag(Args.Advertisers)) { var getter = new ResourceGetter(logger, urls.ListAdvertisers, restCall); restCall.UriVariables.Add("access_id", 1); getter.GotResource += new ResourceGetter.GotResourceEventHandler(getter_GotResource); getter.GetResources(); SaveResources(); } if (args.HasFlag(Args.CampaignGroups)) { var getter = new ResourceGetter(logger, urls.ListCampaignGroups, restCall); getter.GotResource += new ResourceGetter.GotResourceEventHandler(getter_GotResource); getter.GetResources(); SaveResources(); } } catch (Exception e) { Console.WriteLine(e.InnerException); Console.WriteLine(e.StackTrace); }

    Read the article

  • In separate data access & business logic layer, can I use Entity framework classes in business layer

    - by Greg
    In separate data access & business logic layer, can I use Entity framework classes in business layer? EDIT: I don't think I will need to swap out the data access layer from my business logic in the future (i.e. will be SQL Server), however I will for the UI layer. Therefore the question is more meant to be are there any major issues with using EF classes for me in the business layer? Seems like there would be less plumbing code.

    Read the article

  • How to parse a string of boolean logic in PHP

    - by TheOddLinguist
    I'm building a PHP class with a private member function that returns a string value such as: 'true && true || false' to a public member function. (This string is the result of some regex matching and property lookups.) What I'd like to do is have PHP parse the returned logic and have the aforementioned public function return whether the boolean result of the parsed logic is true or false. I tried eval(), but I get no output at all. I tried typecasting the boolean returns...but there's no way to typecast operators...hehe Any ideas? (Let me know if you need more information.)

    Read the article

  • How do I parse boolean logic?

    - by d03boy
    I need to write a boolean logic parser which will translate the boolean logic language to a SQL WHERE clause. The order of the operands will always be in the correct order (with value on the right). Here is a relatively simple example. There could be nested parentheses and the use of NOT operators, etc. (CACOUNT=01 OR CACOUNT=02 OR CACOUNT=03 OR CACOUNT=05 OR CACOUNT=07 OR CACOUNT=09 OR CACOUNT=12 OR CACOUNT=13 OR CACOUNT=18) AND Q4=1 AND NAME=TIMOTHY Here is what the WHERE clause would resemble. WHERE ( EXISTS ( SELECT 1 FROM MyVerticalTable b WHERE b.Key=a.Key AND b.Key='CACOUNT' AND b.Value='01' ) )

    Read the article

  • What logic operator to use, as3?

    - by VideoDnd
    What operator or expression can I use that will fire on every number, including zero? I want a logic operator that will fire with ever number it receives. My animations pause at zero. This skips on zero if (numberThing> 0); This skips on 9 if (numberThing>> 0); This jitters 'fires quickly and goes back on count' if (numberThing== 0); EXPLANATION I'm catching split string values in a logic function, and feeding them to a series of IF, ELSE IF statements. I'm using this with a timer, so I can measure the discrepency. CODE • I GET VALUES FROM TIMER • STRING GOES TO TEXTFIELD 'substr' • NUMBER TRIGGERS TWEENS 'parseInt' • Goes to series of IF and ELSE IF statements

    Read the article

  • Programming knowledge vs. programming logic

    - by Shirish11
    Is there any difference between the two topics? I have seen companies asking for Good Programming knowledge some Good Programming logic. I believe that Programming knowledge is related to knowledge about the language in consideration and Programming logic is problem solving logic using programming (in general). Please correct me if I am wrong. Also what is more important. Edit: Do selection of components for application, designing interfaces validating user inputs fall under programming knowledge or Programming logic? Does programming logic simply imply problem solving, or is there anything else which it should comprise of?

    Read the article

  • Struts logic:iterate input field

    - by camilos
    I currently have the following code and the data is displayed fine. <logic:iterate name="myList" id="product" indexId="iteration" type="com.mycompany.MyBean"> <tr> <td> <bean:write name="product" property="weight"/> </td> <td> <bean:write name="product" property="sku"/> </td> <td> <bean:write name="product" property="quantity"/> </td> </tr> </logic:iterate> But now I need to make the "quantity" part modifiable. The user should be able to update that field, press submit and when its sent to the server, "myList" should automatically update with the new quantities. I've tried searching for help on this but all I keep finding is examples on how to display data only, not modify it. Any help would be appreciated.

    Read the article

  • Is XML a good logic to load data??

    - by Mat
    Hi stack, i'm working on an app that loads some data from xml file from internet. Is this a good way to develop iPhone apps??...I think xml is more light than SQlite database... Basically my logic is: 1 - Parsing Xml file from internet to retrive the data 2 - Load data on device Security?..other stuff??.. Thanks Mat

    Read the article

  • how to refactor tricky logic involving consecutive sets?

    - by keruilin
    The rule at work here is that users can be awarded badges for a streak of 10, 20, and 30. If the user has a streak over 30, such as 40 or 50, then the logic must be that it only awards a 10-streak badge for 40 and a 20-streak badge for 50, and so on. def check_win_streak(streak) badge = 10 while badge < badge::MAX_STREAK_BADGE_SIZE do # MAX_STREAK_BADGE_SIZE = 30 if streak < badge then break end if (streak % badge == 0) then award_streak_badge(badge) end badge += 10 end end

    Read the article

  • web service for business logic or data access layer

    - by luiscarlosch
    This post http://www.theserverside.net/tt/articles/showarticle.tss?id=Top5WSMistakes encourages me to create the web service for business logic layer but many people use it in the data access layer. I want to create a project where i want to access the same data repository from a desktop application, website and a cell phone. What would you recommend me? Is there any case it may be a good idea implement web services to both layers? thanks.

    Read the article

  • logic question about factorials

    - by Syom
    I have a problem and can't solve it alone. My teacher gives me one logic task today, and i'm sure you can help me. How can I count the number of zeroes at the end of factorial(41). (on paper) I understand that it has nothing to do with programing, but I'm sure programers can help me. Thanks in advance.

    Read the article

  • What is the relationship between the business logic layer and the data access layer?

    - by Matt Fenwick
    I'm working on an MVC-ish app (I'm not very experienced with MVC, hence the "-ish"). My model and data access layer are hard to test because they're very tightly coupled, so I'm trying to uncouple them. What is the nature of the relationship between them? Should just the model know about the DAL? Should just the DAL know about the model? Or should both the model and the DAL be listeners of the other? In my specific case, it's: a web application the model is client-side (javascript) the data is accessed from the back-end using Ajax persistence/back-end is currently PHP/MySQL, but may have to switch to Python/GoogleDataStore on the GAE

    Read the article

  • Is the separation of program logic and presentation layer going too far?

    - by Timwi
    In a Drupal programming guide, I noticed this sentence: The theme hook receives the total number of votes and the number of votes for just that item, but the template wants to display a percentage. That kind of work shouldn't be done in a template; instead, the math is performed here. The math necessary to calculate a percentage from a total and a number is (number/total)*100. Is this application of two basic arithmetic operators within a presentation layer already too much? Is the maintenance of the entire system severely compromised by this amount of mathematics? The WPF (Windows Presentation Framework) and its UI mark-up language, XAML, seem to go to similar extremes. If you try to so much as add two numbers in the View (the presentation layer), you have committed a cardinal sin. Consequently, XAML has no operators for any arithmetic whatsoever. Is this ultra-strict separation really the holy grail of programming? What are the significant gains to be had from taking the separation to such extremes?

    Read the article

  • Logic behind crawling an webpages like that of Screaming Frog? [on hold]

    - by sree
    I would like to know what is the parameters to be considered while developing a crawler like that of Screaming Frog. Am looking forward for information on do's and dont's of webpage crawling. What are the problems the crawler may infuse on the webpages like loadtime (maybe?) or anything that effects webpage during crawling. What are the rules the crawler needs to follow etc. Basically anything info that makes the crawler look good and accurate. Just point me in a right direction to achieve it.. Hope my requirement is clear this time.. :)

    Read the article

  • Tool to write linear temporal logic from UML 2.0 sequence diagram

    - by user326180
    i am working on checking model consistency of software. to do this i need to write linear temporal logic for UML 2.0 sequence diagram. if any body have any other tool for the same please response as soon as possible. I will be very obliged to you. i have found charmy tool have plugin for the same. Does anybody have source code for charmy tool(CHecking ARchitectural Model consistencY). It is not available on their website. Thanks in advance.

    Read the article

  • What's wrong with my logic here?

    - by stu
    In java they say don't concatenate Strings, instead you should make a stringbuffer and keep adding to that and then when you're all done, use toString() to get a String object out of it. Here's what I don't get. They say do this for performance reasons, because concatenating strings makes lots of temporary objects. But if the goal was performance, then you'd use a language like C/C++ or assembly. The argument for using java is that it is a lot cheaper to buy a faster processor than it is to pay a senior programmer to write fast efficient code. So on the one hand, you're supposed let the hardware take care of the inefficiencies, but on the other hand, you're supposed to use stringbuffers to make java more efficient. While I see that you can do both, use java and stringbuffers, my question is where is the flaw in the logic that you either use a faster chip or you spent extra time writing more efficient software.

    Read the article

  • High level programming logic, design, pattern

    - by Muhammad Shahzad
    I have been doing programming from last 7 years, getting better and better, but still i think that am lacking something. I have been doing work in JOOMLA, MAGENTO, WP, Custom PHP, Opencart, laravel, codeignitor. Sometimes i need to design logic for a huge database application, in the applications we need nesting loops and queries, although i follow OOPS standards, ORM etc, still i feel i need more robust coding designs. I need to know how can i improve these things, so that code remain neat, efficient and faster. Also how big webapps like facebook twitter tests there code speed? How high level programmers choose design patterns. If you can help me find something useful with examples?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >