diff options
author | Ian Walters <ian.walters@nokia.com> | 2009-05-06 03:56:29 (GMT) |
---|---|---|
committer | Ian Walters <ian.walters@nokia.com> | 2009-05-06 03:56:29 (GMT) |
commit | 9050195e44650b826540b927c0ea6958bc72ad01 (patch) | |
tree | 4ac3f42cc15d2db26ac7e0f222b9c5df947182e9 /examples/declarative/tutorials | |
parent | 36a2adb9970971e2ff82bc4636cafc77211ecb9b (diff) | |
download | Qt-9050195e44650b826540b927c0ea6958bc72ad01.zip Qt-9050195e44650b826540b927c0ea6958bc72ad01.tar.gz Qt-9050195e44650b826540b927c0ea6958bc72ad01.tar.bz2 |
Put more items in the contact table.
Need a few names for scrolling to be demonstrated.
Also still only a few hundred K, so 1000 items not that
big a deal.
Diffstat (limited to 'examples/declarative/tutorials')
-rwxr-xr-x | examples/declarative/tutorials/contacts/shared/contactGenSQL.pl | 82 | ||||
-rw-r--r-- | examples/declarative/tutorials/contacts/shared/contacts.sqlite | bin | 12288 -> 86016 bytes | |||
-rw-r--r-- | examples/declarative/tutorials/contacts/shared/email.txt | 7 | ||||
-rw-r--r-- | examples/declarative/tutorials/contacts/shared/english-f.txt | 143 | ||||
-rw-r--r-- | examples/declarative/tutorials/contacts/shared/english-m.txt | 130 | ||||
-rw-r--r-- | examples/declarative/tutorials/contacts/shared/english-s.txt | 1003 |
6 files changed, 1365 insertions, 0 deletions
diff --git a/examples/declarative/tutorials/contacts/shared/contactGenSQL.pl b/examples/declarative/tutorials/contacts/shared/contactGenSQL.pl new file mode 100755 index 0000000..2d328da --- /dev/null +++ b/examples/declarative/tutorials/contacts/shared/contactGenSQL.pl @@ -0,0 +1,82 @@ +#!/usr/bin/perl + +use warnings; +use strict; + +my $count = shift; + +open(MFIRST, "<english-m.txt") or die "Could not open male names"; +open(FFIRST, "<english-f.txt") or die "Could not open female names"; +open(SURNAME, "<english-s.txt") or die "Could not open surnames names"; +open(ISP, "<email.txt") or die "Could not open isp names"; + +my @mnames = <MFIRST>; +my @fnames = <FFIRST>; +my @surnames = <SURNAME>; +my @isps = <ISP>; + +print "BEGIN;\n"; +print "CREATE TABLE contacts (recid INTEGER PRIMARY KEY, label TEXT, phone TEXT, email TEXT);\n"; +print "CREATE INDEX contactSortOrder ON contacts(label, recid);\n"; + +my $i = 0; +while ($i < $count) { + $i++; + my $fn = randomFirstName(); + my $sn = randomLastName(); + my $em = randomEmail($fn, $sn); + my $ph = randomPhoneNumber(); + + $fn =~ s/'/''/g; + $sn =~ s/'/''/g; + $em =~ s/'/''/g; + print "INSERT INTO contacts (label, email, phone) VALUES('$fn $sn', '$em', '$ph');\n" +} + +print "COMMIT;\n"; + + +sub randomFirstName +{ + my $name; + if (int(rand 2) == 1) { + $name = $mnames[int(rand @mnames)]; + } else { + $name = $fnames[int(rand @fnames)]; + } + chomp $name; + $name; +} + +sub randomLastName +{ + my $name = $surnames[int(rand @surnames)]; + chomp $name; + $name; +} + +sub randomEmail +{ + my ($fn, $ln) = @_; + my $isp = $isps[int(rand @isps)]; + chomp $isp; + my $path = int(rand 3); + my $email; + if ($path == 0) { + $email = "$fn.$ln\@$isp"; + } elsif ($path == 1) { + $email = "$fn\@$isp"; + } elsif ($path == 2) { + $email = "$ln\@$isp"; + } +} + +sub randomPhoneNumber +{ + my @digits = qw(1 2 3 4 5 6 7 8 9 0); + my $phonenumber; + for (1 .. 8) { + $phonenumber .= $digits[int(rand @digits)]; + } + $phonenumber; +} diff --git a/examples/declarative/tutorials/contacts/shared/contacts.sqlite b/examples/declarative/tutorials/contacts/shared/contacts.sqlite Binary files differindex 6918878..d903775 100644 --- a/examples/declarative/tutorials/contacts/shared/contacts.sqlite +++ b/examples/declarative/tutorials/contacts/shared/contacts.sqlite diff --git a/examples/declarative/tutorials/contacts/shared/email.txt b/examples/declarative/tutorials/contacts/shared/email.txt new file mode 100644 index 0000000..de9894b --- /dev/null +++ b/examples/declarative/tutorials/contacts/shared/email.txt @@ -0,0 +1,7 @@ +emails.com +emails.net +mailserver.org +mailserver.net +mailserver.com +BobsMail.com +BillMail.com diff --git a/examples/declarative/tutorials/contacts/shared/english-f.txt b/examples/declarative/tutorials/contacts/shared/english-f.txt new file mode 100644 index 0000000..7da5474 --- /dev/null +++ b/examples/declarative/tutorials/contacts/shared/english-f.txt @@ -0,0 +1,143 @@ +Aimee +Aleksandra +Alice +Alicia +Allison +Alyssa +Amy +Andrea +Angel +Angela +Ann +Anna +Anne +Anne +Marie +Annie +Ashley +Barbara +Beatrice +Beth +Betty +Brenda +Brooke +Candace +Cara +Caren +Carol +Caroline +Carolyn +Carrie +Cassandra +Catherine +Charlotte +Chrissy +Christen +Christina +Christine +Christy +Claire +Claudia +Courtney +Crystal +Cynthia +Dana +Danielle +Deanne +Deborah +Deirdre +Denise +Diane +Dianne +Dorothy +Eileen +Elena +Elizabeth +Emily +Erica +Erin +Frances +Gina +Giulietta +Heather +Helen +Jane +Janet +Janice +Jenna +Jennifer +Jessica +Joanna +Joyce +Julia +Juliana +Julie +Justine +Kara +Karen +Katharine +Katherine +Kathleen +Kathryn +Katrina +Kelly +Kerry +Kim +Kimberly +Kristen +Kristina +Kristine +Laura +Laurel +Lauren +Laurie +Leah +Linda +Lisa +Lori +Marcia +Margaret +Maria +Marina +Marisa +Martha +Mary +Mary +Ann +Maya +Melanie +Melissa +Michelle +Monica +Nancy +Natalie +Nicole +Nina +Pamela +Patricia +Rachel +Rebecca +Renee +Sandra +Sara +Sharon +Sheri +Shirley +Sonia +Stefanie +Stephanie +Susan +Suzanne +Sylvia +Tamara +Tara +Tatiana +Terri +Theresa +Tiffany +Tracy +Valerie +Veronica +Vicky +Vivian +Wendy diff --git a/examples/declarative/tutorials/contacts/shared/english-m.txt b/examples/declarative/tutorials/contacts/shared/english-m.txt new file mode 100644 index 0000000..3c7b13e --- /dev/null +++ b/examples/declarative/tutorials/contacts/shared/english-m.txt @@ -0,0 +1,130 @@ +Aaron +Adam +Adrian +Alan +Alejandro +Alex +Allen +Andrew +Andy +Anthony +Art +Arthur +Barry +Bart +Ben +Benjamin +Bill +Bobby +Brad +Bradley +Brendan +Brett +Brian +Bruce +Bryan +Carlos +Chad +Charles +Chris +Christopher +Chuck +Clay +Corey +Craig +Dan +Daniel +Darren +Dave +David +Dean +Dennis +Denny +Derek +Don +Doug +Duane +Edward +Eric +Eugene +Evan +Frank +Fred +Gary +Gene +George +Gordon +Greg +Harry +Henry +Hunter +Ivan +Jack +James +Jamie +Jason +Jay +Jeff +Jeffrey +Jeremy +Jim +Joe +Joel +John +Jonathan +Joseph +Justin +Keith +Ken +Kevin +Larry +Logan +Marc +Mark +Matt +Matthew +Michael +Mike +Nat +Nathan +Patrick +Paul +Perry +Peter +Philip +Phillip +Randy +Raymond +Ricardo +Richard +Rick +Rob +Robert +Rod +Roger +Ross +Ruben +Russell +Ryan +Sam +Scot +Scott +Sean +Shaun +Stephen +Steve +Steven +Stewart +Stuart +Ted +Thomas +Tim +Toby +Todd +Tom +Troy +Victor +Wade +Walter +Wayne +William diff --git a/examples/declarative/tutorials/contacts/shared/english-s.txt b/examples/declarative/tutorials/contacts/shared/english-s.txt new file mode 100644 index 0000000..1f3682d --- /dev/null +++ b/examples/declarative/tutorials/contacts/shared/english-s.txt @@ -0,0 +1,1003 @@ +Adams +Adamson +Adler +Akers +Akin +Aleman +Alexander +Allen +Allison +Allwood +Anderson +Andreou +Anthony +Appelbaum +Applegate +Arbore +Arenson +Armold +Arntzen +Askew +Athanas +Atkinson +Ausman +Austin +Averitt +Avila-Sakar +Badders +Baer +Baggerly +Bailliet +Baird +Baker +Ball +Ballentine +Ballew +Banks +Baptist-Nguyen +Barbee +Barber +Barchas +Barcio +Bardsley +Barkauskas +Barnes +Barnett +Barnwell +Barrera +Barreto +Barroso +Barrow +Bart +Barton +Bass +Bates +Bavinger +Baxter +Bazaldua +Becker +Beeghly +Belforte +Bellamy +Bellavance +Beltran +Belusar +Bennett +Benoit +Bensley +Berger +Berggren +Bergman +Berry +Bertelson +Bess +Beusse +Bickford +Bierner +Bird +Birdwell +Bixby +Blackmon +Blackwell +Blair +Blankinship +Blanton +Block +Blomkalns +Bloomfield +Blume +Boeckenhauer +Bolding +Bolt +Bolton +Book +Boucher +Boudreau +Bowman +Boyd +Boyes +Boyles +Braby +Braden +Bradley +Brady +Bragg +Brandow +Brantley +Brauner +Braunhardt +Bray +Bredenberg +Bremer +Breyer +Bricout +Briggs +Brittain +Brockman +Brockmoller +Broman +Brooks +Brown +Brubaker +Bruce +Brumfield +Brumley +Bruning +Buck +Budd +Buhler +Buhr +Burleson +Burns +Burton +Bush +Butterfield +Byers +Byon +Byrd +Bzostek +Cabrera +Caesar +Caffey +Caffrey +Calhoun +Call +Callahan +Campbell +Cano +Capri +Carey +Carlisle +Carlson +Carmichael +Carnes +Carr +Carreira +Carroll +Carson +Carswell +Carter +Cartwright +Cason +Cates +Catlett +Caudle +Cavallaro +Cave +Cazamias +Chabot +Chance +Chapman +Characklis +Cheatham +Chen +Chern +Cheville +Chong +Christensen +Church +Claibourn +Clark +Clasen +Claude +Close +Coakley +Coffey +Cohen +Cole +Collier +Conant +Connell +Conte +Conway +Cooley +Cooper +Copeland +Coram +Corbett +Cort +Cortes +Cousins +Cowsar +Cox +Coyne +Crain +Crankshaw +Craven +Crawford +Cressman +Crestani +Crier +Crocker +Cromwell +Crouse +Crowder +Crowe +Culpepper +Cummings +Cunningham +Currie +Cusey +Cutcher +Cyprus +D'Ascenzo +Dabak +Dakoulas +Daly +Dana +Danburg +Danenhauer +Darley +Darrouzet +Dartt +Daugherty +Davila +Davis +Dawkins +Day +DeHart +DeMoss +DeMuth +DeVincentis +Deaton +Dees +Degenhardt +Deggeller +Deigaard +Delabroy +Delaney +Demir +Denison +Denney +Derr +Deuel +Devitt +Diamond +Dickinson +Dietrich +Dilbeck +Dobson +Dodds +Dodson +Doherty +Dooley +Dorsey +Dortch +Doughty +Dove +Dowd +Dowling +Drescher +Drucker +Dryer +Dryver +Duckworth +Dunbar +Dunham +Dunn +Duston +Dettweiler +Dyson +Eason +Eaton +Ebert +Eckhoff +Edelman +Edmonds +Eichhorn +Eisbach +Elders +Elias +Elijah +Elizabeth +Elliott +Elliston +Elms +Emerson +Engelberg +Engle +Eplett +Epp +Erickson +Estades +Etezadi +Evans +Ewing +Fair +Farfan +Fargason +Farhat +Farry +Fawcett +Faye +Federle +Felcher +Feldman +Ferguson +Fergusson +Fernandez +Ferrer +Fine +Fineman +Fisher +Flanagan +Flathmann +Fleming +Fletcher +Folk +Fortune +Fossati +Foster +Foulston +Fowler +Fox +Francis +Frantom +Franz +Frazer +Fredericks +Frey +Freymann +Fuentes +Fuller +Fundling +Furlong +Gainer +Galang +Galeazzi +Gamse +Gannaway +Garcia +Gardner +Garneau +Gartler +Garverick +Garza +Gatt +Gattis +Gayman +Geiger +Gelder +George +Gerbino +Gerbode +Gibson +Gifford +Gillespie +Gillingham +Gilpin +Gilyot +Girgis +Gjertsen +Glantz +Glaze +Glenn +Glotzbach +Gobble +Gockenbach +Goff +Goffin +Golden +Goldwyn +Gomez +Gonzalez +Good +Graham +Gramm +Granlund +Grant +Gray +Grayson +Greene +Greenslade +Greenwood +Greer +Griffin +Grinstein +Grisham +Gross +Grove +Guthrie +Guyton +Haas +Hackney +Haddock +Hagelstein +Hagen +Haggard +Haines +Hale +Haley +Hall +Halladay +Hamill +Hamilton +Hammer +Hancock +Hane +Hansen +Harding +Harless +Harms +Harper +Harrigan +Harris +Harrison +Hart +Harton +Hartz +Harvey +Hastings +Hauenstein +Haushalter +Haven +Hawes +Hawkins +Hawley +Haygood +Haylock +Hazard +Heath +Heidel +Heins +Hellums +Hendricks +Henry +Henson +Herbert +Herman +Hernandez +Herrera +Hertzmann +Hewitt +Hightower +Hildebrand +Hill +Hindman +Hirasaki +Hirsh +Hochman +Hocker +Hoffman +Hoffmann +Holder +Holland +Holloman +Holstein +Holt +Holzer +Honeyman +Hood +Hooks +Hopper +Horne +House +Houston +Howard +Howell +Howley +Huang +Hudgings +Huffman +Hughes +Humphrey +Hunt +Hunter +Hurley +Huston +Hutchinson +Hyatt +Irving +Jacobs +Jaramillo +Jaranson +Jarboe +Jarrell +Jenkins +Johnson +Johnston +Jones +Joy +Juette +Julicher +Jumper +Kabir +Kamberova +Kamen +Kamine +Kampe +Kane +Kang +Kapetanovic +Kargatis +Karlin +Karlsson +Kasbekar +Kasper +Kastensmidt +Katz +Kauffman +Kavanagh +Kaydos +Kearsley +Keleher +Kelly +Kelty +Kendrick +Key +Kicinski +Kiefer +Kielt +Kim +Kimmel +Kincaid +King +Kinney +Kipp +Kirby +Kirk +Kirkland +Kirkpatrick +Klamczynski +Klein +Kopnicky +Kotsonis +Koutras +Kramer +Kremer +Krohn +Kuhlken +Kunitz +LaLonde +LaValle +LaWare +Lacy +Lam +Lamb +Lampkin +Lane +Langston +Lanier +Larsen +Lassiter +Latchford +Lawera +LeBlanc +LeGrand +Leatherbury +Lebron +Ledman +Lee +Leinenbach +Leslie +Levy +Lewis +Lichtenstein +Lisowski +Liston +Litvak +Llano-Restrepo +Lloyd +Lock +Lodge +Logan +Lomonaco +Long +Lopez +Lopez-Bassols +Loren +Loughridge +Love +Ludtke +Luers +Lukes +Luxemburg +MacAllister +MacLeod +Mackey +Maddox +Magee +Mallinson +Mann +Manning +Manthos +Marie +Marrow +Marshall +Martin +Martinez +Martisek +Massey +Mathis +Matt +Maxwell +Mayer +Mazurek +McAdams +McAfee +McAlexander +McBride +McCarthy +McClure +McCord +McCoy +McCrary +McCrossin +McDonald +McElfresh +McFarland +McGarr +McGhee +McGoldrick +McGrath +McGuire +McKinley +McMahan +McMahon +McMath +McNally +Mcdonald +Meade +Meador +Mebane +Medrano +Melton +Merchant +Merwin +Millam +Millard +Miller +Mills +Milstead +Minard +Miner +Minkoff +Minnotte +Minyard +Mirza +Mitchell +Money +Monk +Montgomery +Monton +Moore +Moren +Moreno +Morris +Morse +Moss +Moyer +Mueller +Mull +Mullet +Mullins +Munn +Murdock +Murphey +Murphy +Murray +Murry +Mutchler +Myers +Myrick +Nassar +Nathan +Nazzal +Neal +Nederveld +Nelson +Nguyen +Nichols +Nielsen +Nockton +Nolan +Noonan +Norbury +Nordlander +Norris +Norvell +Noyes +Nugent +Nunn +O'Brien +O'Connell +O'Neill +O'Steen +Ober +Odegard +Oliver +Ollmann +Olson +Ongley +Ordway +Ortiz +Ouellette +Overcash +Overfelt +Overley +Owens +Page +Paige +Pardue +Parham +Parker +Parks +Patterson +Patton +Paul +Payne +Peck +Penisson +Percer +Perez +Perlioni +Perrino +Peterman +Peters +Pfeiffer +Phelps +Philip +Philippe +Phillips +Pickett +Pippenger +Pistole +Platzek +Player +Poddar +Poirier +Poklepovic +Polk +Polking +Pond +Popish +Porter +Pound +Pounds +Powell +Powers +Prado +Preston +Price +Prichep +Priour +Prischmann +Pryor +Puckett +Raglin +Ralston +Rampersad +Ratner +Rawles +Ray +Read +Reddy +Reed +Reese +Reeves +Reichenbach +Reifel +Rein +Reiten +Reiter +Reitmeier +Reynolds +Richardson +Rider +Rhinehart +Ritchie +Rittenbach +Roberts +Robinson +Rodriguez +Rogers +Roper +Rosemblun +Rosen +Rosenberg +Rosenblatt +Ross +Roth +Rowatt +Roy +Royston +Rozendal +Rubble +Ruhlin +Rupert +Russell +Ruthruff +Ryan +Rye +Sabry +Sachitano +Sachs +Sammartino +Sands +Saunders +Savely +Scales +Schaefer +Schafer +Scheer +Schild +Schlitt +Schmitz +Schneider +Schoenberger +Schoppe +Scott +Seay +Segura +Selesnick +Self +Seligmann +Sewall +Shami +Shampine +Sharp +Shaw +Shefelbine +Sheldon +Sherrill +Shidle +Shifley +Shillingsburg +Shisler +Shopbell +Shupack +Sievert +Simpson +Sims +Sissman +Smayling +Smith +Snyder +Solomon +Solon +Soltero +Sommers +Sonneborn +Sorensen +Southworth +Spear +Speight +Spencer +Spruell +Spudich +Stacy +Staebel +Steele +Steinhour +Steinke +Stepp +Stevens +Stewart +Stickel +Stine +Stivers +Stobb +Stone +Stratmann +Stubbers +Stuckey +Stugart +Sullivan +Sultan +Sumrall +Sunley +Sunshine +Sutton +Swaim +Swales +Sweed +Swick +Swift +Swindell +Swint +Symonds +Syzdek +Szafranski +Takimoto +Talbott +Talwar +Tanner +Taslimi +Tate +Tatum +Taylor +Tchainikov +Terk +Thacker +Thomas +Thompson +Thomson +Thornton +Thurman +Thurow +Tilley +Tolle +Towns +Trafton +Tran +Trevas +Trevino +Triggs +Truchard +Tunison +Turner +Twedell +Tyler +Tyree +Unger +Van +Vanderzanden +Vanlandingham +Varanasi +Varela +Varman +Venier +Verspoor +Vick +Visinsky +Voltz +Wagner +Wake +Walcott +Waldron +Walker +Wallace +Walters +Walton +Ward +Wardle +Warnes +Warren +Washington +Watson +Watters +Webber +Weidenfeller +Weien +Weimer +Weiner +Weinger +Weinheimer +Weirich +Welch +Wells +Wendt +West +Westmoreland +Wex +Whitaker +White +Whitley +Wiediger +Wilburn +Williams +Williamson +Willman +Wilson +Winger +Wise +Wisur +Witt +Wong +Woodbury +Wooten +Workman +Wright +Wyatt +Yates +Yeamans +Yen +York +Yotov +Younan +Young +Zeldin +Zettner +Ziegler +Zitterkopf +Zucker |