Search Results

Search found 3722 results on 149 pages for 'choice'.

Page 39/149 | < Previous Page | 35 36 37 38 39 40 41 42 43 44 45 46  | Next Page >

  • How do I handle a user story that I complete, but with compromise and need to revisit?

    - by ProfK
    I have just fulfilled (is that a good term?) two user stories out of a new project backlog I have just built. These are user registration and password reset, both requiring mail. I need to implement a substitute mail component because my initial choice, and a normally reliable one, wasn't working. Because I was focused on delivering the user stories, not debugging the mail component, I swapped it out to deliver working code at sprint end. Do I now log a new support issue for the mailer, or 're-insert' these stories into the backlog? If I do the latter, am I not introducing too much tech detail into user stories?

    Read the article

  • Test iPhone app on iPad mini?

    - by Devfly
    I have developed an iPhone app, right now I only need a device for testing. I have 300$, and two choices - second hand iPhone 4, or brand new iPad mini. The better choice obviously is the iPad, but is it sufficient for testing iPhone apps on? On the iPad, iPhone apps can run just fine in 2X mode, but are there any differences between the app performance on iPhone and iPad (except the chipset). Should I test my app on actual iPhone, or the iPad will suffice? My app is RSS reader, not some game, so I think everything will be fine with testing on iPad mini. If I buy the iPad I will find some friends iPhone 4/3gs running iOS 5.1 (because my app's deployment target is 5.1, and the iPad comes with 6.0), but of course I can't extensively test on this iPhone. Thank you!

    Read the article

  • APress Deal of the Day 10/August/2014 - Pro ASP.NET Web API Security

    - by TATWORTH
    Originally posted on: http://geekswithblogs.net/TATWORTH/archive/2014/08/10/apress-deal-of-the-day-10august2014---pro-asp.net-web.aspxToday’s $10 Deal of the Day from APress at http://www.apress.com/9781430257820 is Pro ASP.NET Web API Security. “ASP.NET Web API is a key part of ASP.NET MVC 4. It has become the platform of choice for building RESTful services. Securing ASP.NET Web API applications requires a move away from traditional WCF-based techniques in favor of new SOAP-less methods. The evaluation, selection and analysis of these new techniques is the focus of this book.”

    Read the article

  • SEO one longer page vs. several targeted subpages?

    - by Travis
    We're working on a site and have come to a choice between one long (not too excessive) main page and several subpages. The subpages would have custom metas/titles/h2 tags and the content that corresponds to them. The main page would have all the content and many more inbound links (pagerank) and with longer content encompassing the content we'd put on the shorter pages. Which would be better for seo and traffic in general? Both schemes are very usable to the user although we are a little concerned with duplicate content (the page's header/footer and other elements remain the same)

    Read the article

  • Analyst Firm Gives Oracle Highest Rating for Local Government CRM

    - by michael.seback
    Gartner, Inc. has given Oracle a rating of "Strong Positive," the highest possible ranking, in its report "MarketScope for Local Government CRM Products." The report compares the offerings of nine providers of CRM commercial off-the-shelf software for local government agencies. Gartner notes that a provider receiving a Strong Positive ranking must be a "provider of strategic products, services or solutions..." and recommends that "customers continue with planned investments and potential customers consider this vendor a strong choice for strategic investments." "Local governments today face tough challenges as they are tasked with reducing costs while at the same time providing citizens with services and information more quickly and efficiently than ever before. Oracle is pleased to be recognized by Gartner with a Strong Positive rating in its 'MarketScope for Local Government CRM Products' report, as we believe it reflects our commitment to helping our public sector customers meet these challenges today and in the future," said Mark Johnson, senior vice president, Oracle Public Sector. Read the highlights.

    Read the article

  • Is there an established convention for separating Windows file names in a string?

    - by Heinzi
    I have a function which needs to output a string containing a list of file paths. I can choose the separation character but I cannot change the data type (e.g. I cannot return a List<string> or something like that). Wanting to use some well-established convention, my first intuition was to use the semicolon, similar to what Windows's PATH and Java's CLASSPATH (on Windows) environment variables do: C:\somedir\somefile.txt;C:\someotherdir\someotherfile.txt However, I was surprised to notice that ; is a valid character in an NTFS file name. So, is the established best practice to just ignore this fact (i.e. "no sane person should use ; in a file name and if they do, it's their own fault") or is there some other established character for separating Windows paths or files? (The pipe (|) might be a good choice, but I have not seen it used anywhere yet for this purpose.)

    Read the article

  • links for 2010-12-08

    - by Bob Rhubart
    Rittman Mead Consulting Blog Archive Oracle BI EE 11g &#8211; Managing Host Name Changes Rittman Mead's Venkatakrishnan J (an Oracle ACE) looks at "how we can go about getting BI EE 11g to work when the Host Name of the machine changes post install and configuration."  (tags: oracle businessintelligence obiee) Evident Software's CTO and co-founder discusses Oracle Coherence (Application Grid) (tags: oracle successcast podcast coherence grid) Choice Hotels' Rain Fletcher talks WebLogic Server (Application Grid) (tags: oracle successcast weblogic podcast) Baz Khuti, CTO of Avocent discusses their next generation application and WebLogic (Application Grid) (tags: oracle successcast podcast) Oracle Counts Clouds | JAVA Developer's Journal "The Independent Oracle Users Group (IOUG), which has 20,000 members, has run up an Oracle-sponsored survey that found significant cloud adoption by Oracle users."  (tags: oracle cloud survey ioug) Oracle Customers Warm to the Cloud | CTO Edge "The Independent Oracle Users Group (IOUG) has published the results of a study on cloud adoption and, to no surprise, the enterprise loves the cloud. " (tags: oracle cloud ioug survey)

    Read the article

  • Partner Webcast – Weblogic for Developers - 12 July 2012

    - by Thanos
    Oracle Weblogic Server is the industry’s leading application server for deploying Java EE applications with support for new features for lowering cost of operations, improving performance and enhancing scalability. But it’s also a great choice for the Java developers because of the differentiating capabilities that facilitate integration with other tools and frameworks, promote reusability and rapid redeployment of your applications. During the webinar we’re going to explore these differentiation features in more detail. Agenda: Java EE standards support in different Weblogic Server versions Weblogic  Classloading How Weblogic load the classes Filtering classloader Shared libraries Classloader Analisys Tool Spring support in Weblogic Weblogic integration with Apache Maven Advanced deployment features Fast Swap Side by Side deployment Q&A session Delivery Format This FREE online LIVE eSeminar will be delivered over the Web. Registrations received less than 24hours prior to start time may not receive confirmation to attend. Duration: 1 hour Register Now! For any questions please contact us at [email protected] Visit regularly our ISV Migration Center blog Or Follow us @oracleimc to learn more on Oracle Technologies as well as upcoming partner webcasts and events.

    Read the article

  • Subscribable World Cup 2010 Calendar

    - by jamiet
    I bang on quite a lot on this blog about ways in which data can get published over the web and one of the most interesting ways, in my opinion, of publishing data in a structured manner that is well understood is to use the iCalendar specification. There isn’t much information in the world that doesn’t have some concept of “when” so iCalendar is a great way of distributing that information. You have probably used iCalendar at some point without even knowing about it. All files with a .ics suffix are iCalendar format files and that is why you can happily import them into Outlook, Hotmail Calendar, Google Calendar etc… where they can be parsed and have the semantic data (when, where and who) extracted from them. Importing of iCalendar format data is really only half the trick though; in my opinion the real value of iCalendar-formatted calendar is the ability to subscribe to them. Subscribing has a simple benefit over importing but that single benefit is of massive importance: a subscriber to an iCalendar calendar can periodically check to see if any updates have been made and, if they have, automatically update the local copy. The real benefit to the user is the productivity gain – a single update to an iCalendar means that all subscribers are automatically made aware of the change and there is zero effort on the part of the subscriber; as my former colleague Howard van Rooijen is fond of saying, “work smarter not harder” – nowhere is this edict more ably demonstrated than subscribing versus importing of calendars. If you want to read some more thoughts about iCalendar then go and read my past blog post Calendar syndication - My big hope for 2009's breakthrough technology or better still go and seek out Jon Udell who speaks very authoritatively on the issue of iCalendar. With this subject of iCalendar on my mind I was interested to discover (via Steve Clayton’s blog post Download the world cup fixtures) that the BBC had made a .ics file available containing all of the matches in the upcoming World Cup. As you can probably guess this was a file that was made available so that it could be imported into your calendar of choice. It had one obvious downside though, right now nobody knows who is going to be playing in the knock-out stages so the calendar looks like this: with no teams being named after 25th June. How much more useful would this calendar have been if the BBC had made it possible to subscribe to the calendar instead, thus the calendar could be updated with the teams for the knock out stages when they are known and every subscriber would have a permanently up-to-date record of all the fixtures in their calendar. Better still, the calendar could be updated with match results as well or perhaps even post a match report from the BBC sport pages; when calendars are made subscribable a sea of opportunity opens up for distribution of information. So with that in mind I have decided to go one better than the BBC. I have imported their .ics into a brand new Hotmail calendar and made it publicly available at the following URLs: HTML http://cid-dc1ed121af0476be.calendar.live.com/calendar/World+Cup+2010/index.html iCalendar webcal://cid-dc1ed121af0476be.calendar.live.com/calendar/World+Cup+2010/calendar.ics The link you’re really interested in is the second one - click on that and it should open up in your calendar software of choice. Or, if you want to view it in an online calendar such as Hotmail Calendar or Google Calendar, copy and paste that URL into the appropriate place. Some people have told me they’re having trouble with the iCalendar link in which case hit the HTML link and then click “View ICS” at the resultant web page: I shall endeavour to keep the calendar updated throughout the World Cup and even if I don’t you’re no worse off than if you had imported the BBC’s .ics file so why not give it a try? If I do keep it up to date then you will have a permanent record of the 2010 World Cup available in your calendar. Forever. If you have your calendar synced to your smartphone then you’ll be carrying match reports around with you without you having to do a single thing. Surely that’s worth a quick click isn’t it?   If you have any thoughts let me have them in the comments below. Thanks for reading. @Jamiet Share this post: email it! | bookmark it! | digg it! | reddit! | kick it! | live it!

    Read the article

  • How meaningful is the Big-O time complexity of an algorithm?

    - by james creasy
    Programmers often talk about the time complexity of an algorithm, e.g. O(log n) or O(n^2). Time complexity classifications are made as the input size goes to infinity, but ironically infinite input size in computation is not used. Put another way, the classification of an algorithm is based on a situation that algorithm will never be in: where n = infinity. Also, consider that a polynomial time algorithm where the exponent is huge is just as useless as an exponential time algorithm with tiny base (e.g., 1.00000001^n) is useful. Given this, how much can I rely on the Big-O time complexity to advise choice of an algorithm?

    Read the article

  • How do I deal with analysis paralysis?

    - by Anne Nonimus
    Very frequently, I am stuck when choosing the best design decision. Even for small details, such as function definitions, control flow, and variable names, I spend unusually long periods perusing the benefits and trade-offs of my choices. I feel like I am losing a lot of efficiency by spending my hours on insignificant details like these. Even though, I know in the back of my mind that I can change these things if my current design doesn't work out, I have trouble deciding firmly on one choice. What should I do to combat this problem?

    Read the article

  • Starting off with web dev with php

    - by pavan kumar
    I'm currently working with Java / C++. I'm interested in web development and am planning to shift my stream. I heard that PHP is a good platform to start off and also it does not require that much of knowledge in technologies like JSP / Servlets or frameworks like springs / struts / hibernate. I have basic ideas about HTML and Javascript as well. I have gone through previous posts in SO and found out the relevant resources as well: http://net.tutsplus.com/tutorials/php/the-best-way-to-learn-php/ http://www.webhostingtalk.com/archive/index.php/t-1028265.html http://www.killerphp.com/ http://phpforms.net/tutorial/tutorial.html http://www.php5-tutorial.com/ etc. Now, my question is: I heard of PHP frameworks like CodeIgniter, Zend Frameworkd and Yii. Doesn't learning PHP & MySql implicitly makes us aware of these frameworks? Am I making a good choice in stating with PHP? Is it a good idea to shift streams?

    Read the article

  • Using GridView and DetailsView in ASP.NET MVC - Part 1

    - by bipinjoshi
    For any beginner in ASP.NET MVC the first disappointment is possibly the lack of any server controls. ASP.NET MVC divides the entire processing logic into three distinct parts namely model, view and controller. In the process views (that represent UI under MVC architecture) need to sacrifice three important features of web forms viz. Postbacks, ViewState and rich event model. Though server controls are not a recommended choice under ASP.NET MVC there are situations where you may need to use server controls. In this two part article I am going to explain, as an example, how GridView and DetailsView can be used in ASP.NET MVC without breaking the MVC pattern.http://www.bipinjoshi.net/articles/59b91531-3fb2-4504-84a4-9f52e2d65c20.aspx 

    Read the article

  • Announcing the New Windows Azure Web Sites Shared Scaling Tier

    - by Clint Edmonson
    Windows Azure Web Sites has added a new pricing tier that will solve the #1 blocker for the web development community. The shared tier now supports custom domain names mapped to shared-instance web sites. This post will outline the plan changes and elaborate on how the new pricing model makes Windows Azure Web Sites an even richer option for web development shops of all sizes. Free Shared Reserved # of Sites 10 100 100 Egress 165MB/Day 5GB/Month Included 5GB/Month Included Storage 1GB 1GB 10GB Throttling CPU/Memory/Egress CPU/Memory Unlimited Price Free $.02/hr per site, per instance $.08/hr per core Setting the Stage In June, we released the first public preview of Windows Azure Web Sites, which gave web developers a great platform on which to get web sites running using their web development framework of choice. PHP, Node.js, classic ASP, and ASP.NET developers can all utilize the Windows Azure platform to create and launch their web sites. Likewise, these developers have a series of data storage options using Windows Azure SQL Databases, MySQL, or Windows Azure Storage. The Windows Azure Web Sites free offer enabled startups to get their site up and running on Windows Azure with a minimal investment, and with multiple deployment and continuous integration features such as Git, Team Foundation Services, FTP, and Web Deploy.  The response to the Windows Azure Web Sites offer has been overwhelmingly positive. Since the addition of the service on June 12th, tens of thousands of web sites have been deployed to Windows Azure and the volume of adoption is increasing every week. Preview Feedback In spite of the growth and success of the product, the community has had questions about features lacking in the free preview offer. The main question web developers asked regarding Windows Azure Web Sites relates to the lack of the free offer’s support for domain name mapping. During the preview launch period, customer feedback made it obvious that the lack of domain name mapping support was an area of concern. We’re happy to announce that this #1 request has been delivered as a feature of the new shared plan. New Shared Tier Portal Features In the screen shot below, the “Scale” tab in the portal shows the new tiers – Free, Shared, and Reserved – and gives the user the ability to quickly move any of their free web sites into the shared tier. With a single mouse-click, the user can move their site into the shared tier. Once a site has been moved into the shared tier, a new Manage Domains button appears in the bottom action bar of the Windows Azure Portal giving site owners the ability to manage their domain names for a shared site. This button brings up the domain-management dialog, which can be used to enter in a specific domain name that will be mapped to the Windows Azure Web Site. Shared Tier Benefits Startups and large web agencies will both benefit from this plan change. Here are a few examples of scenarios which fit the new pricing model: Startups no longer have to select the reserved plan to map domain names to their sites. Instead, they can use the free option to develop their sites and choose on a site-by-site basis which sites they elect to move into the shared plan, paying only for the sites that are finished and ready to be domain-mapped Agencies who manage dozens of sites will realize a lower cost of ownership over the long term by moving their sites into reserved mode. Once multi-site companies reach a certain price point in the shared tier, it is much more cost-effective to move sites to a reserved tier.  Long-term, it’s easy to see how the new Windows Azure Web Sites shared pricing tier makes Windows Azure Web Sites it a great choice for both startups and agency customers, as it enables rapid growth and upgrades while keeping the cost to a minimum. Large agencies will be able to have all of their sites in their own instances, and startups will have the capability to scale up to multiple-shared instances for minimal cost and eventually move to reserved instances without worrying about the need to incur continually additional costs. Customers can feel confident they have the power of the Microsoft Windows Azure brand and our world-class support, at prices competitive in the market. Plus, in addition to realizing the cost savings, they’ll have the whole family of Windows Azure features available. Continuous Deployment from GitHub and CodePlex Along with this new announcement are two other exciting new features. I’m proud to announce that web developers can now publish their web sites directly from CodePlex or GitHub.com repositories. Once connections are established between these services and your web sites, Windows Azure will automatically be notified every time a check-in occurs. This will then trigger Windows Azure to pull the source and compile/deploy the new version of your app to your web site automatically. Walk-through videos on how to perform these functions are below: Publishing to an Azure Web Site from CodePlex Publishing to an Azure Web Site from GitHub.com These changes, as well as the enhancements to the reserved plan model, make Windows Azure Web Sites a truly competitive hosting option. It’s never been easier or cheaper for a web developer to get up and running. Check out the free Windows Azure web site offering and see for yourself. Stay tuned to my twitter feed for Windows Azure announcements, updates, and links: @clinted

    Read the article

  • How do people get around the Carmack's Reverse patent?

    - by Rei Miyasaka
    Apparently, Creative has a patent on Carmack's Reverse, and they successfully forced Id to modify their techniques for the source drop, as well as to include EAX in Doom 3. But Carmack's Reverse is discussed quite often and apparently it's a good choice for deferred shading, so it's presumably used in a lot of other high-budget productions too. Even though it's unlikely that Creative would go after smaller companies, I'm wondering how the bigger studios get around this problem. Do they just cross their fingers and hope Creative doesn't troll them, or do they just not use Carmack's Reverse at all?

    Read the article

  • Ubuntu Lagging even LXDE freezes

    - by Anas Ismail Khan
    Laptop, i3, Ram: 2GB. Using 14.04LTS... and it lags like hell. Even if i open more than 4 tabs in Chrome, it freezes, and often I have no choice but to restart and multi-tasking is kinda difficult and at times impossible. Now there's whole thing about Lubuntu and LXDE that are suposed to be super-fast.. installed LXDE.. mind, not lubuntu-desktop. just LXDE. And it too freezes every now and then, and trust this.. when it freezes, it does so worse than Unity.. ESPECIALLY when i start PCManFM... and mount a disk or two... Any ideas as to why this is happening.. The minimum requirements for Unity are supposed to be 1Gig RAM.. and people are running it fine even on 512 MB...

    Read the article

  • Cross-Browser Extension Installation now Possible with Opera and Google Chrome

    - by Akemi Iwaya
    People have been curious if there would be cross-browser compatibility for extensions due to Opera’s recent switch to the browser engine that Google Chrome uses. That question has now been answered. The OMG! Chrome! Blog has put together a nice tutorial on how to get cross-browser extension compatibility set up and working with your browser of choice. Screenshot courtesy of OMG! Chrome! Blog. While it is not surprising that the first steps in cross-browser extension compatibility have been taken, it will be interesting to see how it develops as the process is refined and further development occurs with the ‘new’ Opera. What are your thoughts on this? Is cross-browser extension compatibility really that important? Perhaps you feel that it does not matter? Let us know your thoughts in the comments!    

    Read the article

  • Best Free software for hosting user guides

    - by Hippyjim
    Hi All After having to clean up spam from a MediaWiki install for the umpteenth time, despite a recaptcha plugin "preventing" automated signups, I'm wondering if MediaWiki is the right choice as a CMS for hosting user manuals and guides. I've always loved the way wikis can let the guides be edited and commented on collaboratively, but I'm getting tired of dealing with automated vandals. I've disabled edits & signups for now, but as I'm having to go through the pain of cleaning thousands of junk pages, I'm beginning to think I should cut my losses and look for a better alternative. Does anyone know of suitable a FOSS application (preferably PHP / MySQL based) that would be simple for a non-coder (our manual writer) to edit, but that has all the interconnectivity, and searchability of a wiki? Or should I just bite the bullet again and lock the wiki down even further?

    Read the article

  • Designing A 2-Way SSL RESTful API

    - by Mithir
    I am starting to develop a WCF API, which should serve some specific clients. We don't know which devices will be using the API so I thought that using a RESTful API will be the most flexible choice. All devices using the API would be authenticated using an SSL certificate (client side certificate), and our API will have a certificate as well ( so its a 2 Way SSL) I was reading this question over SO, and I saw the answers about authentication using Basic-HTTP or OAuth, but I was thinking that in my case these are not needed, I can already trust the client because it possesses the client-side certificate. Is this design ok? Am I missing anything? Maybe there's a better way of doing this?

    Read the article

  • Changing Platform

    - by Liam McLennan
    From time to time a developer makes a break from their platform of choice (.NET, Java, VB, Access, COBOL) and moves to perceived greener pastures. Zed Shaw did it, jumping from Ruby to Python, and Mike Gunderloy went from .NET to Rails. But it can be difficult to change platform. My clients don’t come to me looking for  a software developer, they come looking for a .NET developer. This is a tragic side effect of big software companies marketing. If your village is under attack by bandits, would you turn away the first seven samurai who offered to help because you didn’t like their swords? What matters is how effectively they can defend your village. You should not tell your carpenter what sort of hammer to use and you should not tell your software developer what platform to use.

    Read the article

  • How to choose a job? [closed]

    - by Aadi Droid
    When given multiple opportunities from various software giants, as a fresher out of school how should one decide which company to go for? Just as an example I have offers from two companies, won't name them but the two biggest dream companies for any SDE. While one company offers tremendous learning opportunites and and a good pay but coupled with really bad employee support and perks. While the other offers a relaxed work environment where learning happens by choice, with a slightly lower pay but amazing employee facilities and perks. Assuming the fresher has a plan to go for his masters degree in two years what are the most important things he should be looking at?

    Read the article

  • Removing a File Association

    - by Anthony Trudeau
    I found a rather simple way to remove a file association (default program) tonight that I thought others might find useful.  I found it after discovering that Windows 7 doesn't provide a straight-forward way of removing an association.Windows 7 provides a nice interface in the Control Panel for changing associations (Programs > Default Programs > Set Associations), but once you have one you cannot get rid of it.  The Registry is an obvious choice, because that's where the associations are stored.  In fact, the HKEY_CLASSES_ROOT hive has the association, but there is also a key you need to delete somewhere in the HKEY_CURRENT_USER hive.Doing a little poking around, I discovered a command line program called ASSOC that'll do it.  And typing HELP ASSOC confirms that it was what I was looking for.  The solution to my problem turned out to be as simple as typing ASSOC .BIN="" on the command line.

    Read the article

  • Mobile game production workflow using Html5 and visual studio

    - by Mihalis Bagos
    I want to know of any framework, that lets you build/test applications inside Visual Studio using Html5/JS. We need to be able to have an emulator (like the one on android sdk) for as many devices as possible, and we need to be able to run the application with as few steps as possible (using the "RUN" command in visual studio is no1 choice). Also, this extends to build and deployment to app stores. Is there a way to circumvent the cloud services and build locally? I am at a loss of the plethora of tools and technologies available for game design using Html5. However, I really don't like the way implementations try to get you to rely on their cloud services, so services like appmobi are at the bottom of the favored list.

    Read the article

  • 12.04: Having problem with REISUB

    - by Jerry-bliss
    Often my ubuntu freezes up altogether(only able to move my cursor). So i try to reboot using the keys "ALT+PrntScrn+REISUB", but this is what happens Once i finish hitting the keys RE, my screen goes BLACK and it shows up a few lines of commands (or whatever) which I dont understand. I have no other choice other than manually force shut down (by pressing power button for 3-4 seconds) Here is a screenshot of what my black screen displays as soon as I hit R,E What do these lines mean? Is there anyway I can safely restart my PC? (Since i was unable to use printscreen, i had to manually take a snap of my monitor using my camera. I had taken 3 pictures of the same screen, because I could not capture the entire text displayed on my screen in a single click)

    Read the article

  • The Template Method Design Pattern using C# .Net

    - by nijhawan.saurabh
    First of all I'll just put this pattern in context and describe its intent as in the GOF book:   Template Method: Define the skeleton of an algorithm in an operation, deferring some steps to Subclasses. Template Method lets subclasses redefine certain steps of an algorithm without changing the Algorithm's Structure.    Usage: When you are certain about the High Level steps involved in an Algorithm/Work flow you can use the Template Pattern which allows the Base Class to define the Sequence of the Steps but permits the Sub classes to alter the implementation of any/all steps.   Example in the .Net framework: The most common example is the Asp.Net Page Life Cycle. The Page Life Cycle has a few methods which are called in a sequence but we have the liberty to modify the functionality of any of the methods by overriding them.   Sample implementation of Template Method Pattern:   Let's see the class diagram first:            Normal 0 false false false EN-US X-NONE X-NONE /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin-top:0in; mso-para-margin-right:0in; mso-para-margin-bottom:8.0pt; mso-para-margin-left:0in; line-height:107%; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman"; mso-bidi-theme-font:minor-bidi; mso-font-kerning:1.0pt; mso-ligatures:standard;}   And here goes the code:EmailBase.cs     1 using System;     2 using System.Collections.Generic;     3 using System.Linq;     4 using System.Text;     5 using System.Threading.Tasks;     6      7 namespace TemplateMethod     8 {     9     public abstract class EmailBase    10     {    11     12         public bool SendEmail()    13         {    14             if (CheckEmailAddress() == true) // Method1 in the sequence    15             {    16                 if (ValidateMessage() == true) // Method2 in the sequence    17                 {    18                     if (SendMail() == true) // Method3 in the sequence    19                     {    20                         return true;    21                     }    22                     else    23                     {    24                         return false;    25                     }    26     27                 }    28                 else    29                 {    30                     return false;    31                 }    32     33             }    34             else    35             {    36                 return false;    37     38             }    39     40     41         }    42     43         protected abstract bool CheckEmailAddress();    44         protected abstract bool ValidateMessage();    45         protected abstract bool SendMail();    46     47     48     }    49 }    50    EmailYahoo.cs      1 using System;     2 using System.Collections.Generic;     3 using System.Linq;     4 using System.Text;     5 using System.Threading.Tasks;     6      7 namespace TemplateMethod     8 {     9     public class EmailYahoo:EmailBase    10     {    11     12         protected override bool CheckEmailAddress()    13         {    14             Console.WriteLine("Checking Email Address : YahooEmail");    15             return true;    16         }    17         protected override bool ValidateMessage()    18         {    19             Console.WriteLine("Validating Email Message : YahooEmail");    20             return true;    21         }    22     23     24         protected override bool SendMail()    25         {    26             Console.WriteLine("Semding Email : YahooEmail");    27             return true;    28         }    29     30     31     }    32 }    33   EmailGoogle.cs      1 using System;     2 using System.Collections.Generic;     3 using System.Linq;     4 using System.Text;     5 using System.Threading.Tasks;     6      7 namespace TemplateMethod     8 {     9     public class EmailGoogle:EmailBase    10     {    11     12         protected override bool CheckEmailAddress()    13         {    14             Console.WriteLine("Checking Email Address : GoogleEmail");    15             return true;    16         }    17         protected override bool ValidateMessage()    18         {    19             Console.WriteLine("Validating Email Message : GoogleEmail");    20             return true;    21         }    22     23     24         protected override bool SendMail()    25         {    26             Console.WriteLine("Semding Email : GoogleEmail");    27             return true;    28         }    29     30     31     }    32 }    33   Program.cs      1 using System;     2 using System.Collections.Generic;     3 using System.Linq;     4 using System.Text;     5 using System.Threading.Tasks;     6      7 namespace TemplateMethod     8 {     9     class Program    10     {    11         static void Main(string[] args)    12         {    13             Console.WriteLine("Please choose an Email Account to send an Email:");    14             Console.WriteLine("Choose 1 for Google");    15             Console.WriteLine("Choose 2 for Yahoo");    16             string choice = Console.ReadLine();    17     18             if (choice == "1")    19             {    20                 EmailBase email = new EmailGoogle(); // Rather than newing it up here, you may use a factory to do so.    21                 email.SendEmail();    22     23             }    24             if (choice == "2")    25             {    26                 EmailBase email = new EmailYahoo(); // Rather than newing it up here, you may use a factory to do so.    27                 email.SendEmail();    28             }    29         }    30     }    31 }    32    Final Words: It's very obvious that why the Template Method Pattern is a popular pattern, everything at last revolves around Algorithms and if you are clear with the steps involved it makes real sense to delegate the duty of implementing the step's functionality to the sub classes. Normal 0 false false false EN-US X-NONE X-NONE /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin-top:0in; mso-para-margin-right:0in; mso-para-margin-bottom:8.0pt; mso-para-margin-left:0in; line-height:107%; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman"; mso-bidi-theme-font:minor-bidi; mso-font-kerning:1.0pt; mso-ligatures:standard;}

    Read the article

< Previous Page | 35 36 37 38 39 40 41 42 43 44 45 46  | Next Page >