Search Results

Search found 408 results on 17 pages for 'na'.

Page 8/17 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • Konszolidációs stratégiák az Oracle Database Machine-hez webcast, 2010. június 16.

    - by Fekete Zoltán
    Az utóbbi hetekben két tanfolyamon vettem részt, így a blogbejegyzések nem szaporodtak. Na most újult erovel. :) Regisztráció a webcast-ra. Holnap, azaz 2010. június 16-án 18h-kor (közép-európai ido) csatlakozhatunk a Consolidation Strategies for Oracle Database Machine, azaz a Konszolidációs stratégiák az Oracle Database Machine-hez címu webcasthoz, amit az Oracle BIWA és az Exadata SIG (Special Interest Group) rendez meg. Az eloadó: Dave Norris, aki az Oracle X Team tagja. Exadata SIG: http://OracleExadata.org BIWA SIG http://OracleBIWA.org The Oracle Database Machine V2 (the Exadata system) offers customers the opportunity to run combinations of consolidated workloads for both data warehousing (DW) and online transaction processing (OLTP) while maintaining superior performance. Regisztráció a webcast-ra.

    Read the article

  • « On explore sur l'iPad, on achète sur un ordinateur » : une étude de Miratech

    « On explore sur l'iPad, mais on achète sur un ordinateur » Une étude de Miratech Miratech a réalisé une étude comparant la navigation Internet entre iPad et ordinateur. Conclusion : l'ordinateur est beaucoup plus efficace pour des tâches spécifiques et l'iPad est plus ludique pour explorer du contenu. Voici le contenu de l'étude : Un échantillon de 20 utilisateurs équi-répartis, familiers avec l'iPad, a été testé dans nos laboratoires de test utilisateur. Il leur était demandé de naviguer sur cinq sites web connus en France disposant aussi d'une application iPad (Amazon, La Redoute, Allociné, Les Pages Jaunes et Voyages SNCF). Nous avons testé les na...

    Read the article

  • Team Foundation Server (TFS) Team Build Custom Activity C# Code for Assembly Stamping

    - by Bob Hardister
    For the full context and guidance on how to develop and implement a custom activity in Team Build see the Microsoft Visual Studio Rangers Team Foundation Build Customization Guide V.1 at http://vsarbuildguide.codeplex.com/ There are many ways to stamp or set the version number of your assemblies. This approach is based on the build number.   namespace CustomActivities { using System; using System.Activities; using System.IO; using System.Text.RegularExpressions; using Microsoft.TeamFoundation.Build.Client; [BuildActivity(HostEnvironmentOption.Agent)] public sealed class VersionAssemblies : CodeActivity { /// <summary> /// AssemblyInfoFileMask /// </summary> [RequiredArgument] public InArgument<string> AssemblyInfoFileMask { get; set; } /// <summary> /// SourcesDirectory /// </summary> [RequiredArgument] public InArgument<string> SourcesDirectory { get; set; } /// <summary> /// BuildNumber /// </summary> [RequiredArgument] public InArgument<string> BuildNumber { get; set; } /// <summary> /// BuildDirectory /// </summary> [RequiredArgument] public InArgument<string> BuildDirectory { get; set; } /// <summary> /// Publishes field values to the build report /// </summary> public OutArgument<string> DiagnosticTextOut { get; set; } // If your activity returns a value, derive from CodeActivity<TResult> and return the value from the Execute method. protected override void Execute(CodeActivityContext context) { // Obtain the runtime value of the input arguments string sourcesDirectory = context.GetValue(this.SourcesDirectory); string assemblyInfoFileMask = context.GetValue(this.AssemblyInfoFileMask); string buildNumber = context.GetValue(this.BuildNumber); string buildDirectory = context.GetValue(this.BuildDirectory); // ** Determine the version number values ** // Note: the format used here is: major.secondary.maintenance.build // ----------------------------------------------------------------- // Obtain the build definition name int nameStart = buildDirectory.LastIndexOf(@"\") + 1; string buildDefinitionName = buildDirectory.Substring(nameStart); // Set the primary.secondary.maintenance values // NOTE: these are hard coded in this example, but could be sourced from a file or parsed from a build definition name that includes them string p = "1"; string s = "5"; string m = "2"; // Initialize the build number string b; string na = "0"; // used for Assembly and Product Version instead of build number (see versioning best practices: **TBD reference) // Set qualifying product version information string productInfo = "RC2"; // Obtain the build increment number from the build number // NOTE: this code assumes the default build definition name format int buildIncrementNumberDelimterIndex = buildNumber.LastIndexOf("."); b = buildNumber.Substring(buildIncrementNumberDelimterIndex + 1); // Convert version to integer values int pVer = Convert.ToInt16(p); int sVer = Convert.ToInt16(s); int mVer = Convert.ToInt16(m); int bNum = Convert.ToInt16(b); int naNum = Convert.ToInt16(na); // ** Get all AssemblyInfo files and stamp them ** // Note: the mapping of AssemblyInfo.cs attributes to assembly display properties are as follows: // - AssemblyVersion = Assembly Version - used for the assembly version (does not change unless p, s or m values are changed) // - AssemblyFileVersion = File Version - used for the file version (changes with every build) // - AssemblyInformationalVersion = Product Version - used for the product version (can include additional version information) // ------------------------------------------------------------------------------------------------------------------------------------------------ Version assemblyVersion = new Version(pVer, sVer, mVer, naNum); Version newAssemblyFileVersion = new Version(pVer, sVer, mVer, bNum); Version productVersion = new Version(pVer, sVer, mVer); // Setup diagnostic fields int numberOfReplacements = 0; string addedAssemblyInformationalAttribute = "No"; // Enumerate over the assemblyInfo version attributes foreach (string attribute in new[] { "AssemblyVersion", "AssemblyFileVersion", "AssemblyInformationalVersion" }) { // Define the regular expression to find in each and every Assemblyinfo.cs files (which is for example 'AssemblyVersion("1.0.0.0")' ) Regex regex = new Regex(attribute + @"\(""\d+\.\d+\.\d+\.\d+""\)"); foreach (string file in Directory.EnumerateFiles(sourcesDirectory, assemblyInfoFileMask, SearchOption.AllDirectories)) { string text = File.ReadAllText(file); // Read the text from the AssemblyInfo file // If the AsemblyInformationalVersion attribute is not in the file, add it as the last line of the file // Note: by default the AssemblyInfo.cs files will not contain the AssemblyInformationalVersion attribute if (!text.Contains("[assembly: AssemblyInformationalVersion(\"")) { string lastLine = Environment.NewLine + "[assembly: AssemblyInformationalVersion(\"1.0.0.0\")]"; text = text + lastLine; addedAssemblyInformationalAttribute = "Yes"; } // Search for the expression Match match = regex.Match(text); if (match.Success) { // Get file attributes FileAttributes fileAttributes = File.GetAttributes(file); // Set file to read only File.SetAttributes(file, fileAttributes & ~FileAttributes.ReadOnly); // Insert AssemblyInformationalVersion attribute into the file text if does not already exist string newText = string.Empty; if (attribute == "AssemblyVersion") { newText = regex.Replace(text, attribute + "(\"" + assemblyVersion + "\")"); numberOfReplacements++; } if (attribute == "AssemblyFileVersion") { newText = regex.Replace(text, attribute + "(\"" + newAssemblyFileVersion + "\")"); numberOfReplacements++; } if (attribute == "AssemblyInformationalVersion") { newText = regex.Replace(text, attribute + "(\"" + productVersion + " " + productInfo + "\")"); numberOfReplacements++; } // Publish diagnostics to build report (diagnostic verbosity only) context.SetValue(this.DiagnosticTextOut, " Added AssemblyInformational Attribute: " + addedAssemblyInformationalAttribute + " Number of replacements: " + numberOfReplacements + " Build number: " + buildNumber + " Build directory: " + buildDirectory + " Build definition name: " + buildDefinitionName + " Assembly version: " + assemblyVersion + " New file version: " + newAssemblyFileVersion + " Product version: " + productVersion + " AssemblyInfo.cs Text Last Stamped: " + newText); // Write the new text in the AssemblyInfo file File.WriteAllText(file, newText); // restore the file's original attributes File.SetAttributes(file, fileAttributes); } } } } } }

    Read the article

  • Registering as developer on Google Play store

    - by ChosenOne
    I am registering as a Developer to sell paid applications on the Google Play store and have run into a slight issue: After I paid, I clicked on "Setup merchant details" link. I filled out the business address section, but in the "Public contact" section, Google says this: How can your customers get in touch with you? This information will be made available to your customers when they make a purchase. I work from home. I do not want customers knowing my home address, nor do I want it displayed anywhere online or even accessible by anyone. Should I just enter NA in each of the following fields? Surely Google understands that we have a right to keep such things private? How can I get around this while not getting my account suspended or risk not being approved?

    Read the article

  • Moonlight stopped working on tvp.pl

    - by Oliverka
    Hello, I'm watching The Bold and the beautiful on the site: http://www.tvp.pl/seriale/obyczajowe/moda-na-sukces/wideo Yesterday I wanted to view next episode, however it didn't work. I checked various episodes from other points in time and none works. The "dots" that appear when a Silverlight video is loading are present, but after them there is only black screen (of death). I'm using Ubuntu Lucid Lynx 32 bit with GNOME2 and firefox 3.6. I have all updates done. Could somebody check if any video is working for them and tell me their setup, please? I'm using Moonlight 3. Two days ago everything was fine but later this problem appeared.

    Read the article

  • How to make Pokémon White 3D effect?

    - by Pipo
    I just wondered how to create a 3D effect similar to Pokemon White/Black? It seems to be not polygon based, but created just with sprites. If the perspective changes the sprites stay sharp and don't get blurred. How can I archive this? Source: https://www.youtube.com/watch?v=fZEPUPYOnRc&feature=youtube_gdata_player Edit: Wow, two downvotes because I used a video instead of screenshots? Don't get me wrong, I thank you, because you want to help me, but the 3D effect can be better understand in motion. Anyway, here is a screenshot: http://wearearcade.com/wp-content/uploads/2011/03/pokemon-black-white-starter-town.jpg So, if this is a hardware limitation, how can I archive this o na different hardware, e.g. a HTML5 game? Thank you.

    Read the article

  • La place de marché des Google Apps se dote de 16 nouveaux services en ligne, pour les entreprises et

    La place de marché des Google Apps se dote de 16 nouveaux services en ligne, des outils variés pour les entreprise et les administrateurs Le Google Apps Marketplace, lancé le 10 mars dernier à destination des entreprises, vient de se voir crédité de 16 nouveaux services en ligne, s'appliquant à des domaines aussi divers que le collaboratif ou bien le montage vidéo. Certaines de ses nouveautés sont payantes, les autres sont gratuites. Toutes sont proposées par des éditeurs tiers. Les administrations trouveront leur bonheur parmi ces outils divers et variés, dont voici un petit tour d'horizon : - Applane CRM : solution de gestion de la relation client en mode hébergé accessible depuis Google Universal Na...

    Read the article

  • Problemas com instalação do Ubuntu 12.04 LTS e 13.04

    - by user160096
    Não consegui, apesar de diversas tentativas, instalar nenhuma das versões: 12.04 LTS e 13.04. Cheguei a trocar de mouse,uma vez que o anterior não era reconhecido pelo sistema. Configuração: Motherboard Gigabyte GA-970A-D3 8 Gb de memória DDR-3 1 Hd Sata II Samsung de 80Gb, com Windows 7 Ultimate SP-1 1 Hd Sata II de 1Tb Samsung, como dispositivo de dados 1 Monitor 23" Phiips CL 234 1 Placa de Vídeo Gigayte NVidia GeForce GT-220 1 Placa Ethernet Realtek RTL 8139/810x 1 Mouse Microsoft (com software IntelliPoint 8.2) 1 Mouse Logitech M-100 (que usei para subsitutir o da Microsoft, SEM SUCESSO!!!) Na última tentativa, o instalador do ubuntu (tanto no 12.04 quanto no 13.04, PASMEM, não reconheceu o Win7 instalado...foi aí que 'JOGUEI A TOALHA"...! Apesar de minha simpatia pela liberdade e SO's livres e bons, dificuldades como esta desencorajam a transição/migração do usuário... É de se pensar sobre isto...!

    Read the article

  • Problem with Moonlight

    - by Oliverka
    Hello, I'm watching The Bold and the beautiful on the site: http://www.tvp.pl/seriale/obyczajowe/moda-na-sukces/wideo Yesterday I wanted to view next episode, however it didn't work. I checked various episodes from other points in time and none works. The "dots" that appear when a Silverlight video is loading are present, but after them there is only black screen (of death). I'm using Ubuntu Lucid Lynx 32 bit with GNOME2 and firefox 3.6. I have all updates done. Could somebody check if any video is working for them and tell me their setup, please? Best regards. Oliverka

    Read the article

  • Error when updating BlackBerry JDE Plug-in for Eclipse (v5.0 Beta 3) ?

    - by Ashraf Bashir
    I tried to update Blackberry JDE plug-in for eclipse from v4.5 to v5.0 Beta 3. I followed the instructions in this page: http://na.blackberry.com/eng/developers/devbetasoftware/updatesite.jsp but unfortunately I got the following error while updating: An error occurred while collecting items to be installed. No repository found containing: net.rim.eide.feature.componentpack5.0.0/org.eclipse.update.feature/5.0.0.14 How this could be solved ? Any suggestions ?

    Read the article

  • Adding multiple vectors in R

    - by Elais
    I have a problem where I have to add thirty-three integer vectors of equal length from a dataset in R. I know the simple solution would be Vector1 + Vector2 + Vector3 +VectorN But I am sure there is a way to code this. Also some vectors have NA in place of integers so I need a way to skip those. I know this may be very basic but I am new to this.

    Read the article

  • how to push one view to another view?

    - by MD
    In my application there are two view.First view na dsecond view. In my second view there is one time for 60 sec.When i go first view to second view then timr is start.when i back to first view thne timer is running in background.when timer is over then one popup is generated.When i click on pop up(ok button) then i want to go in second view.Acctully pop is in second view. How to solve this problem

    Read the article

  • Motion detection in compressed domain (JPEG/Mpeg4/H264)

    - by paft
    everyone! I process video from IP cameras and have wrote a motion detection algorithm based on decompressed video analysis. But i really something more fast. I've found several papers about compressed domain analysis but have failed to find any implementations. Can anyone recommend me some code? found materials: http://www.ist-live.org/intranet/school-of-informatics-university-of-bradford001-7/41410206.pdf/view http://doc.rero.ch/lm.php?url=1000,43,4,20061128120121-NA/Bracamonte_Javier_-_A_Low_Complexity_Change_Detection_Algorithm_20061128.pdf

    Read the article

  • How to successfully implement og:image for the LinkedIn

    - by Sabo
    THE PROBLEM: I am trying, without much success, to implement open graph image on site: http://www.guarenty-group.com/cz/ The homepage is completeply bypassing the og:image tag, where internal pages are reading all images from the site and place og:image as the last option. Other social networks are working fine on both internal pages and homepage. THE CONFIGURATION: I have no share buttons or alike, all I want is to be able to share the link via my profile. The image is well over 300x300px: http://guarenty-group.com/img/gg_seal.png Here is how my head tag looks like: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Guarenty Group : Pojištení pro nájemce a pronajímatelé</title> <meta name="keywords" content="" /> <meta name="description" content="Guarenty Group pojištuje príjem z nájmu pronajímatelum, kauci nájemcum - aby nemuseli platit velkou cástku v hotovostí predem - a dále nájemcum pojištuje príjmy, aby meli na nájem pri nemoci, úrazu ci nezamestnání." /> <meta name="image_src" content="http://guarenty-group.com/img/gg_seal.png" /> <meta name="image_url" content="http://guarenty-group.com/img/gg_seal.png" /> <meta property="og:title" content="Pojištení pro nájemce a pronajímatelé" /> <meta property="og:url" content="http://guarenty-group.com/cz/" /> <meta property="og:image" content="http://guarenty-group.com/img/gg_seal.png" /> <meta property="og:description" content="Guarenty Group pojištuje príjem z nájmu pronajímatelum, kauci nájemcum - aby nemuseli platit velkou cástku v hotovostí predem - a dále nájemcum pojištuje príjmy, aby meli na nájem pri nemoci, úrazu ci nezamestnání [...]" /> ... </head> THE TESTING RESULTS: In order to trick the cache i have tested the site with http://www.guarenty-group.com/cz/?try=N, where I have changed the N every time. The strange thing is that images found for different value of N is different. Sometimes there is no image, sometimes there is 1, 2 or 3 images, but each time there is a different set of images. But, in any case I could not find the image specified in the og:graph! MY QUESTIONS: https://developer.linkedin.com/documents/setting-display-tags-shares is saying one thing, and the personnel on the support forum is saying "over 300" Does anyone know What is the official minimum dimension of the image (both w and h)? Can an image be too large? Should I use the xmlns, should I not use xmlns or it doesn't matter? What are the maximum (and minimum) lengths for og:title and og:description tags? Any other suggestion is of course welcomed :) Thanks in advance, cheers~

    Read the article

  • How to fix the position of the button in applet

    - by user1609804
    I'm trying to make an applet that has a buttons in the right, where each button is corresponding to a certain pokemon. I already did it, but the buttons isn't fixed.they keep following the mouse. please help. This is my code: import javax.swing.*; import java.awt.image.BufferedImage; import java.io.*; import javax.imageio.ImageIO; import java.applet.*; import java.awt.event.*; import java.awt.*; public class choosePokemon extends Applet implements ActionListener { private int countPokemon; private int[] storePokemon; private int x,y; //this will be the x and y coordinate of the button BufferedImage Picture; public int getCountPokemon(){ //for other class that needs how many pokemon return countPokemon; } public int[] getStoredPokemon(){ //for other class that needs the pokemon return storePokemon; } public void init(){ x=0;y=0; try{ Picture = ImageIO.read(new File("pokeball.png")); } catch( IOException ex ){ } } public void paint( Graphics g ){ pokemon display = new pokemon(); // to access the pokemon attributes in class pokemon ButtonGroup group = new ButtonGroup(); //create a button group for( int a=0;a<16;a++ ){ // for loop in displaying the buttons of every pokemon(one pokemon, one button) display.choose( a ); //calls the method choose in which accepts an integer from 0-15 and saves the attributes of the pokemon corresponding to the integer JButton pokemonButton = new JButton( display.getName() ); // creates the button pokemonButton.setActionCommand( display.getName() ); // isasave sa actioncommand yung name ng kung ano mang pokemon pokemonButton.addActionListener(this); //isasama yung bagong gawang button sa listener para malaman kung na-click yung button pokemonButton.setBounds( x,y,50,23 ); group.add( pokemonButton ); //eto naman yung mag-aadd sa bagong gawang button sa isang group na puro buttons(button ng mga pokemon) y+=23; if( a==7 ){ x+=50; y=0; } add( pokemonButton ); //will add the button to the applet } g.drawImage( Picture, 120, 20, null ); } public void actionPerformed(ActionEvent e) { try{ //displays the picture of the selected pokemon Picture = ImageIO.read(new File( "pokemon/" + e.getActionCommand() + ".png" )); } catch( IOException ex ){ } } public boolean chosen( int PChoice ){ //this will check if the chosen pokemon is already the player's pokemon boolean flag = false; for( int x=0; x<countPokemon && !flag ;x++ ){ if( storePokemon[x]==PChoice ){ flag = true; } } return flag; }

    Read the article

  • linq to entites left outer join

    - by parminder
    I am struggling linq to entities left outer join. I have two entities (tables): Listings { ListingID, MakeID (nullable) } Makes { MakeID, Description } I want to write something like this in LINQ: select listings.listingID ,listings.makeid , IsNull(makes.Description, 'NA') from listings left outer join makes on listings.makeid = makes.makeid

    Read the article

  • Remove a layer from a ggplot2 chart

    - by Erik Shilts
    I'd like to remove a layer (in this case the results of geom_ribbon) from a ggplot2 created grid object. Is there a way I can remove it once it's already part of the object? library(ggplot2) dat <- data.frame(x=1:3, y=1:3, ymin=0:2, ymax=2:4) p <- ggplot(dat, aes(x=x, y=y)) + geom_ribbon(aes(ymin=ymin, ymax=ymax), alpha=0.3) + geom_line() # This has the geom_ribbon p # This overlays another ribbon on top p + geom_ribbon(aes(ymin=ymin, ymax=ymax, fill=NA))

    Read the article

  • R: Plotting a graph with different colors of points based on advanced criteria

    - by balconydoor
    What I would like to do is a plot (using ggplot), where the x axis represent years which have a different colour for the last three years in the plot than the rest. The last three years should also meet a certain criteria and based on this the last three years can either be red or green. The criteria is that the mean of the last three years should be less (making it green) or more (making it red) than the 66%-percentile of the remaining years. So far I have made two different functions calculating the last three year mean: LYM3 <- function (x) { LYM3 <- tail(x,3) mean(LYM3$Data,na.rm=T) } And the 66%-percentile for the remaining: perc66 <- function(x) { percentile <- head(x,-3) quantile(percentile$Data, .66, names=F,na.rm=T) } Here are two sets of data that can be used in the calculations (plots), the first which is an example from my real data where LYM3(df1) < perc66(df1) and the second is just made up data where LYM3 perc66. df1<- data.frame(Year=c(1979:2010), Data=c(347261.87, 145071.29, 110181.93, 183016.71, 210995.67, 205207.33, 103291.78, 247182.10, 152894.45, 170771.50, 206534.55, 287770.86, 223832.43, 297542.86, 267343.54, 475485.47, 224575.08, 147607.81, 171732.38, 126818.10, 165801.08, 136921.58, 136947.63, 83428.05, 144295.87, 68566.23, 59943.05, 49909.08, 52149.11, 117627.75, 132127.79, 130463.80)) df2 <- data.frame(Year=c(1979:2010), Data=c(sample(50,29,replace=T),75,75,75)) Here’s my code for my plot so far: plot <- ggplot(df1, aes(x=Year, y=Data)) + theme_bw() + geom_point(size=3, aes(colour=ifelse(df1$Year<2008, "black",ifelse(LYM3(df1) < perc66(df1),"green","red")))) + geom_line() + scale_x_continuous(breaks=c(1980,1985,1990,1995,2000,2005,2010), limits=c(1978,2011)) plot As you notice it doesn’t really do what I want it to do. The only thing it does seem to do is that it turns the years before 2008 into one level and those after into another one and base the point colour off these two levels. Since I don’t want this year to be stationary either, I made another tiny function: fun3 <- function(x) { df <- subset(x, Year==(max(Year)-2)) df$Year } So the previous code would have the same effect as: geom_point(size=3, aes(colour=ifelse(df1$Year<fun3(df1), "black","red"))) But it still does not care about my colours. Why does it make the years into levels? And how come an ifelse function doesn’t work within another one in this case? How would it be possible to the arguments to do what I like? I realise this might be a bit messy, asking for a lot at the same time, but I hope my description is pretty clear. It would be helpful if someone could at least point me in the right direction. I tried to put the code for the plot into a function as well so I wouldn’t have to change the data frame at all functions within the plot, but I can’t get it to work. Thank you!

    Read the article

  • problem with list return type??

    - by kaushik
    my list has value such as m=[['na','1','2']['ka','31','45']['ra','3','5'] d=0 r=2 t=m[d][r] print t # this is givin number i.e 2 Now when I use this value u=[] u=m[t] I am getting an err msg saying type error list does take str values... i want to use like this how can i convert that t into a integer?? please suggest.. thanks..

    Read the article

  • why is ADODB inserting NULL values on update?

    - by every_answer_gets_a_point
    i have: With rs .AddNew ' create a new record ' add values to each field in the record .Fields("datapath") = dpath .Fields("analysistime") = "atime" .Fields("reporttime") = "rtime" .Fields("lastcalib") = "lcalib" .Fields("analystname") = "aname" .Fields("reportname") = "rname" .Fields("batchstate") = "bstate" .Fields("instrument") = "NA" .Update ' stores the new record End With when i check the database, it looks like it ONLY inserted the last field! has anyone encountered this problem?

    Read the article

  • How to merge two test into one RSpec

    - by thefonso
    Both the last two test work individually...but when both are set to run (non pending) I get problems. question: can I create a test that merges the two into one? How would this look?(yes, I am new to rspec) require_relative '../spec_helper' # the universe is vast and infinite....and...it is empty describe "tic tac toe game" do context "the game class" do before (:each) do player_h = Player.new("X") player_c = Player.new("O") @game = Game.new(player_h, player_c) end it "method drawgrid must return a 3x3 game grid" do @game.drawgrid.should eq("\na #{$thegrid[:a1]}|#{$thegrid[:a2]}|#{$thegrid[:a3]} \n----------\nb #{$thegrid[:b1]}|#{$thegrid[:b2]}|#{$thegrid[:b3]} \n----------\nc #{$thegrid[:c1]}|#{$thegrid[:c2]}|#{$thegrid[:c3]} \n----------\n 1 2 3 \n") @game.drawgrid end #FIXME - last two test here - how to merge into one? it "play method must display 3x3 game grid" do STDOUT.should_receive(:puts).and_return("\na #{$thegrid[:a1]}|#{$thegrid[:a2]}|#{$thegrid[:a3]} \n----------\nb #{$thegrid[:b1]}|#{$thegrid[:b2]}|#{$thegrid[:b3]} \n----------\nc #{$thegrid[:c1]}|#{$thegrid[:c2]}|#{$thegrid[:c3]} \n----------\n 1 2 3 \n").with("computer move") @game.play end it "play method must display 3x3 game grid" do STDOUT.should_receive(:puts).with("computer move") @game.play end end end just for info here is the code containing the play method require_relative "player" # #Just a Tic Tac Toe game class class Game #create players def initialize(player_h, player_c) #bring into existence the board and the players @player_h = player_h @player_c = player_c #value hash for the grid lives here $thegrid = { :a1=>" ", :a2=>" ", :a3=>" ", :b1=>" ", :b2=>" ", :b3=>" ", :c1=>" ", :c2=>" ", :c3=>" " } #make a global var for drawgrid which is used by external player class $gamegrid = drawgrid end #display grid on console def drawgrid board = "\n" board << "a #{$thegrid[:a1]}|#{$thegrid[:a2]}|#{$thegrid[:a3]} \n" board << "----------\n" board << "b #{$thegrid[:b1]}|#{$thegrid[:b2]}|#{$thegrid[:b3]} \n" board << "----------\n" board << "c #{$thegrid[:c1]}|#{$thegrid[:c2]}|#{$thegrid[:c3]} \n" board << "----------\n" board << " 1 2 3 \n" return board end #start the game def play #draw the board puts drawgrid #external call to player class @player = @player_c.move_computer("O") end end player_h = Player.new("X") player_c = Player.new("O") game = Game.new(player_h, player_c) game.play

    Read the article

  • difference between cn.execute and rs.update?

    - by every_answer_gets_a_point
    i am connecting to mysql from excel using odbc. the following illustrates how i am updating the rs With rs .AddNew ' create a new record ' add values to each field in the record .Fields("datapath") = dpath .Fields("analysistime") = atime .Fields("reporttime") = rtime .Fields("lastcalib") = lcalib .Fields("analystname") = aname .Fields("reportname") = rname .Fields("batchstate") = "bstate" .Fields("instrument") = "NA" .Update ' stores the new record End With the question is why is there a need to run cn.execute after this? havent i already updated the rs with rs.update?

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >