Posts

Showing posts from April, 2014

r - Scaling for estimating scale and shape parameter with fitdist function (fitdistrplus package) -

as specified in title have scaling problem fitdist function in r ( fitdistrplus package). please have @ following code: # initialize arrays storing result fit_store_scale <- rep(na, 3) fit_store_shape <- rep(na, 3) # load data data1 <- c(7.616593e-05, 5.313253e-05, 1.604328e-04, 6.482365e-05, 4.217499e-05, 6.759114e-05, 3.531301e-05, 1.934228e-05, 6.263665e-05, 8.796205e-06) data2 <- c(7.616593e-06, 5.313253e-06, 1.604328e-05, 6.482365e-06, 4.217499e-06, 6.759114e-06, 3.531301e-06, 1.934228e-06, 6.263665e-06, 8.796205e-07) data3 <- c(7.616593e-07, 5.313253e-07, 1.604328e-06, 6.482365e-07, 4.217499e-07, 6.759114e-07, 3.531301e-07, 1.934228e-07, 6.263665e-07, 8.796205e-08) # form data frame data <- data.frame(data1, data2, data3) # set scaling factor scaling <- 1 #works without warnings , errors at: #10000 (data1), 100000 (data2) or #100000

javascript - Textarea hashtag highlight is applied to the wrong position after the first line -

when going newline , starting hashtag there beginning of line, highlighter applying color previous line. <style> #input{ color: transparent; } #input b{ text-decoration: none; color: transparent; background-color: #9aceff; font-weight: normal; } #t{ background-color: transparent; } </style> <textarea id="t" style="width: 342px; height: 92px; resize: none; position: absolute; z-index: 1; border: 1px solid #212;font-family: arial; padding: 20px; margin: 0; font-size: 12px;"> </textarea> <div style="width: 300px; height: 50px; border: 1px solid #212; font-family: arial; padding: 20px; position: absolute; z-index: 0; margin: 0; font-size: 12px;" id="input"> </div> <script> $(document).ready(function(){ $('#t').on('input keyup', function() {

angularjs - angular.js sets model to null when ng-options filtered -

i have course category , course list select inputs. according selected courses, want filter ng-options user won't select same courses twice <td> <select ng-show="course._courseid" class="form-control" ng-model="course.lookup_course_id" ng-options="s.id s.name s in subcourses[course._courseid] | filter:notselectedcourse"> <option value="">select course</option> </select> </td> and i'm using following function filter selected courses $scope.notselectedcourse = function(scourse) { if (!$scope.course_list) return true; (var d, = 0; < $scope.course_list.length; i++) { d = $scope.course_list[i]; if (d.lookup_course_id == scourse.id) return false; } return true; }; however, angular.js doesn't update second selectbox value , update model. when disable filter, works fine need add filter user

Creating records using macro in Clojure -

i want define vector values want use in record , pass vector macro creates record. (def keys ['data1 'data2 'data3]) (defmacro make-record [n v & body] `(defrecord ~n ~v ~@body)) (make-record vud vud-keys) (macroexpand-1 '(make-record type keys)) -> (defrecord type keys) what want is: (macroexpand-1 '(make-record type keys)) -> (defrecord type ['data1 'data2 'data3]) it looks need evaluate arguments during macroexpansion. eval does. (def keys '[data1 data2 data3]) (defmacro make-record [name keys] `(defrecord ~name ~(eval keys)))

How to directly get value from array via key in node.js -

i'ld price value directly via categoryname key in following array without loop node.js. possible? priceitem [ { _id: 561e92d7b5737103130a374b, price: ‘1000', categoryname: '561e7cbd288906ab3fa3b52b' } { _id: 561e92d7b5737103130a374c, price: ‘2000', categoryname: '561e7cc3288906ab3fa3b52c' } { _id: 561e92d7b5737103130a374d, price: ‘3000', categoryname: '561e3c3aabf5d47634c465bd' } { _id: 561e92d7b5737103130a374e, price: ‘4000', categoryname: '561e3c3eabf5d47634c465be' } { _id: 561e92d7b5737103130a374f, price: ‘5000', categoryname: '561e6439249dced339d529a1’ } ] i think acceptable: function getpricebycategory(categoryname) { var retval = ''; (var = 0; < priceitem.length; i++) { if (priceitem[i].categoryname === categoryname) { retval = priceitem[i].price; break; } }

android - How differentiate between user input and setText method in TextWatcher? -

i'm using recyclerview contains items containing edittext each one. i add textwatcher in edittext in viewholder constructor. text watcher call: adapter.notifyitemchanged() when bind views, do: edittext.settext("value"); so text changed event fired, don't want beacuse get java.lang.illegalstateexception: cannot call method while recyclerview computing layout or scrolling i want event fired when user changes text manually. there way differentiate events? i remove , add again textwatcher each time views binded i'd find better solution. instead of setting textwatcher in viewholder constructor, can while binding view, right after settext() call, avoiding problem experiencing. so: edittext.settext("value"); edittext.settextwatcher(new textwatcher(.. this way textwatcher not fire event because didn't yet exist when initial value set.

android - Floating Textfields Yahoo Range Seek Bar -

first using range seek bar https://github.com/anothem/android-range-seek-bar but ofcourse of more funktions etc. tried forked version https://github.com/yahoo/android-range-seek-bar the sample project running nice on device problem is, if try integrate libary in existing app. i edited gradle.build compile 'com.yahoo.mobile.client.android.util.rangeseekbar:rangeseekbar-library:0.1.0' and runs without errors but problem me know, cant seekbar same in sampleproject. in 1 have "floating textfields" on seekbar, can see, whats actual point on seekbar. other thing is, buttons way bigger on example project on app. in layout , mainactivity files sample project nothing special, rly dont know search changes. would rly nice if of me fix little problem.

eclipse - How to Resolve 'not found: object anorm' for play 2.4.3 -

i'm using play 2.4.3 , when import anorm like import anorm._ import anorm.sqlparser._ this brings error message below in ide... not found: object anorm but project execute (without throwing error). dependencies librarydependencies ++= seq("com.typesafe.play" %% "anorm" % "2.3.6") editor eclipse luna scala version scalaversion := "2.11.6" activator version 1.3.6 os windows 8 your imports incorrect - should be: import anorm._ import anorm.sqlparser._ note difference on second import. hth

php - Login and registering not working on live server -

this link site: http://210.48.154.18/~econtrax/ezy/index.php oddly, can't admin's dashboard page after uploaded live server. i've no idea why can't through login , registering function. i made sure data exists in database. , noticed in network tab pages accessed not working! in console tab error thrown i've no idea on how fix them. could me fix please. may try login with following: email: admin@gmail.com password: admin or may try creating new user! thanks lot this! my login script: /*login user*/ <!--login form submission starts--> $("document").ready(function () { $("#login-user").submit(function () { var data = { "action": "test" }; data = $(this).serialize() + "&" + $.param(data); $.ajax({ type: "post", datatype: "json", url: "login-this-user.php", data: data, success: function (data) { a

visual studio code - Kill Process that is created from running a task -

i launching task , works great task stays running in current shell. there anyway kill task editor when done? not sure if have tried. press ctrl+p . type >task terminate .

javascript - Expressjs module bodyparser returns undefined -

i playing around simple html form, trying parse form data. unfortunately routes section returns undefined form elements my app.js var express = require('express'); var path = require('path'); var favicon = require('serve-favicon'); var logger = require('morgan'); var cookieparser = require('cookie-parser'); var bodyparser = require('body-parser'); var busboy = require('connect-busboy'); var routes = require('./routes/index'); var users = require('./routes/users'); var app = express(); // view engine setup app.set('views', path.join(__dirname, 'views')); app.set('view engine', 'jade'); // uncomment after placing favicon in /public //app.use(favicon(path.join(__dirname, 'public', 'favicon.ico'))); app.use(logger('dev')); app.use(bodyparser.json()); app.use(bodyparser.urlencoded({ extended: true })); app.use(cookieparser()); app.use(express.static(pa

vba - change link file path in excel -

i know if possible change file path of link in excel, using text in cell. trick here source workbook not open @ same time 1 has link in it, , not located in same folder. ie: if once cell has link like: ='c:\thanks\forthehelp\01\[eg.xlsx]worksheet'!a1 and want change file based on text input cell, ie: cell a1 has text: "02" ='c:\thanks\forthehelp\&a1&\[eg.xlsx]worksheet'!a1 to ='c:\thanks\forthehelp\02\[eg.xlsx]worksheet'!a1 i know above example doesn't work, think illustrates want here. appreciated. hope makes sense. thanks. you use indirect function implement constucted string destination workbook indirect not work on closed workbooks. a vba routine replace formula in cell. range("a1").formula = replace(range("a1").formula, "\01\", "\02\") if opt sort of formula replacement, should check ensure external workbook exists in new location akin dir function . using

Send array of floats as HTTP POST request in php -

i writing script executed client generate array of floats (which understand in php supposed same doubles) , perform post request page take data , compute mean, returning data in response. plan attach send array in message body in json format. found tutorial online doing post requests in php have taken function do_post_request() , can't around following exception: php fatal error: uncaught exception 'exception' message 'problem http://localhost/average.php' in /home/yak/restclient.php:20 stack trace: #0 /home/yak/restclient.php(5): do_post_request('http://localhos...', '[1.5,1.5,1.5,1....', 'content-type=ap...') #1 {main} thrown in /home/yak/restclient.php on line 20 the client code: <?php $array = array_fill(0,5,1.5); $data = json_encode($array); echo $data; $response = do_post_request("http://localhost/average.php",$data,"content-type=application/json"); echo $response; function do_post_request($url,

asp.net core - Method not found: 'Void Microsoft.AspNet.Razor.CodeGenerators.GeneratedTagHelperContext -

i upgraded project asp.net 5 beta 7 beta 8 , keep getting following error not able solbe: missingmethodexception: method not found: 'void microsoft.aspnet.razor.codegenerators.generatedtaghelpercontext.set_htmlencoderpropertyname(system.string)'. microsoft.aspnet.mvc.razor.mvcrazorhost..ctor(ichunktreecache chunktreecache, razorpathnormalizer pathnormalizer) i have following packages on project: "microsoft.aspnet.mvc.taghelpers": "6.0.0-beta8", "microsoft.aspnet.razor": "4.0.0-beta8-15575", "microsoft.aspnet.razor.runtime": "4.0.0-beta8-15575", what missing? remove razor , razor.runtime. i used depenency "entityframework.commands": "7.0.0-beta8", "entityframework.sqlserver": "7.0.0-beta8", "microsoft.applicationinsights.aspnet": "1.0.0-beta8", "microsoft.aspnet.authentication.cookies": "1.0.0-beta8&quo

coq tactic - How to introduce a new existential condition from a witness in Coq? -

my question relates how construct exist term in set of conditions/hypotheses. i have following intermediate proof state: x : type p : x -> prop h : (exists x : x, p x -> false) -> false x : x h0 : p x -> false ______________________________________(1/1) p x in mind, know because of h0 , x witness (exists x : x, p x -> false) , , want introduce name: w: (exists x : x, p x -> false) based on above reasoning , use apply h in w generate false in hypothesis, , inversion false . but don't know tactic/syntax use introduce witness w above. best can reach far check (ex_intro _ (fun x => p x -> false) x h0)). gives false . can explain how introduce existential condition, or alternative way finish proof? thanks. p.s. have whole theorem prove is: theorem not_exists_dist : excluded_middle -> forall (x:type) (p : x -> prop), ~ (exists x, ~ p x) -> (forall x, p x). proof. unfold excluded_middle. unfold not. intros exm x

android - Cannot use CCLOG in eclipse. the msg won't show up in my LogCat -

please, me. thank much. new , learning develop android app watching tutorial video. trying use cclog in eclipse. uppercase. try print following msg. cclog("test string"); cclog("visiblesize:%.1f,%.1f",visiblesize.width,visiblesize.height); cclog("origin:%.1f,%.1f",origin.x,origin.y); they don't show in eclipse logcat, when use visual studio, show in output. i have tried following methods. didn't work. put #define cocos2d_debug 1 @ top (higher #include) in cpp file add -dccocos2d_debug=1 in application.mk file this: app_cppflags := -frtti -dcc_enable_chipmunk_integration=1 -std=c++11 -fsigned-char -dccocos2d_debug=1 it helloworldscene of cocos2d-x #define cocos2d_debug 1 #include "helloworldscene.h" using_ns_cc; scene* helloworld::createscene() { // 'scene' autorelease object auto scene = scene::create(); // 'layer' autorelease object auto layer = helloworld::create(); // add layer child scene scene-&

java - Can we make the order of one list based on other? -

i have 2 array lists list1 , list2 , want list2 order order of list1 . there way this? in 1 list got top performing emploee database , list 2 got database second time using top performing employee ids using "in" clause. list<long> list1 = new arraylist<long>(); list1.add(5645); list1.add(2312); list1.add(7845); list1.add(1212); and other list of object type: list<employee> list2 = new arraylist<employee>(); list2.add(new employee(1212, "a")); list2.add(new employee(2312, "v")); list2.add(new employee(5645, "d")); list2.add(new employee(7845, "t")); where list1 shows employee id of top 4; and got employee detail data base using id , got list2. now want make order of list2 list1 show on html page. just iterate list1 , each item find matching element in list2 . no need sort. list<employee> sortedlist = new arraylist<>(); (long id : list1) { employee match = collec

c# - SelectedItem doesn't update properly when trying to share items between views -

i have scenario same collection of items can viewed in different ways. is, have multiple visual representations same data. in order keep our application visually clean can view 1 of these views @ time. problem i'm having if change selected item while viewing view #1 when switch view #2 selected item isn't updating properly. my steps reproducing: on view #1 select item #1. toggle view #2 - @ point item #1 selected scroll down "item #200" , select it toggle view #1 item #1 still highlighted , if scroll down item #200 highlighted it seems when listbox collapsed selection changes aren't being picked up. missing? expected propertychanged events won't update ui elements if aren't visible? i have simplified version of code below. basically, have shared array being bound 2 different listbox controls. xaml: <window x:class="sharedlistbindingexample.mainwindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/pres

How to create a cluster for TIBCO EMS? -

i've created administration domain on windows node, need create cluster , add node cluster.how go it? there no concept of "cluster" (in wmq sense) ems, there notions of "connected ems servers" (routes), , bridging of queues (bridges, not unlike wmq remote queues). there notion of "multi-instance local ha". you may want : plan ems deployment strategy, proper balance latency, availability, license cost , performance execute plan by: seting local ha, shared fs if shared state needed ( here article on that ) make use of "routes" feature of ems link multiple ems ha instances (see page 569 of the user guide ) note : if have limited number of instances massive amount of clients, consider multicast or product (like ftl or rabbitmq).

Java HTTP server sending chunked response -

i working on java application has built in http server, @ moment server implemented using serversocketchannel, listens on port 1694 requests: msvrch = serversocketchannel.open(); msvrch.socket().bind(new inetsocketaddress(mintport)); msvrch.configureblocking(false); a thread installed manage requests , responses: thread thrd = new thread(msgreceiver); thrd.setuncaughtexceptionhandler(exceptionhandler); thrd.start(); the thread quite simple: runnable msgreceiver = new runnable() { @override public void run() { try{ while( !thread.interrupted() ) { //sleep short period between checks new requests try{ thread.sleep(delay_between_accepts); } catch(exception ex) { ex.printstacktrace(); }

c# - Ternary operator in LINQ query is not working as expected -

i'm trying filter list of objects based on conditions. i've seen few posts use ternary operators in linq query accomplish this. at bottom of code snippet linq query. expected test each where , instead seems try first where , leave rest. list not contain data expect to. doing wrong? private observablecollection<logevent> m_logevents = applicationdata.mainlogentries.logevents; public observablecollection<logevent> logevents { { return m_logevents; } set { m_logevents = value; raisepropertychanged("logevents"); } } private bool m_viewdebuglogs = false; public bool viewdebuglogs { { return m_viewdebuglogs; } set { m_viewdebuglogs = value; raisepropertychanged("viewdebuglogs"); filterlist(); } } private bool m_viewerrorlogs = true; public bool viewerrorlogs { { return m_viewerrorlogs; } set { m_viewerrorlogs = value; raisepropertychanged("view

Java - JLabel lose image and a new appear on front -

Image
i have big jlabel picture, i'd user enters mouse on it, lose image , others small pictures appear in it, close each other. family tree, main image tree, , when mouse entered, small pics of plebs appear next each other, pic below. use: jlabel c = new jlabel(); c.setborder(new etchedborder(etchedborder.raised)); c.seticon(new imageicon("c:\\users\\lud\\desktop\\family\\tree.png")); c.setbackground(new color(192, 192, 192)); c.setopaque(true); c.setbounds(5, 5, 256, 256); c.addmouselistener(new mouseadapter() { public void mouseentered(mouseevent me) { c.seticon(null); jlabel c1 = new jlabel(); c1.seticon(new imageicon("c:\\users\\lud\\desktop\\family\\george.png")); c1.setbounds(10, 10, 32, 32); add(c1); } public void mouseexited(mouseevent me) { } }); add(c); the main jlabel/tree image appears fine when enter mouse on it, loses picutes without display

c - PBC element_to_bytes error "prints garbage" Unable to convert element to string -

i getting garbage values when convert element_t string. reason? element_printf("element_a: %b",a); //int len = element_length_in_bytes(a); unsigned char* stra= (unsigned char*)malloc(element_length_in_bytes(a)*sizeof(char)); element_to_bytes(stra,a); printf("\n\n\n a: %s\n\n\n",stra); the output is: element_a: 676879270129030191324293305775237511254264666883 a: v�p��?�p�+��a�����[ i want normal print element_a. missing? thanks, yogesh you not getting garbage , not converting element string. passing array of bytes printf , tell function interpret them characters. no surprise not work. try element_snprint() element_printf("element_a: %b",a); size_t s = (size_t) element_length_in_bytes(a); char* stra= (char*)malloc(s*sizeof(char)); element_snprint(stra, s, a) printf("\n\n\n a: %s\n\n\n",stra);

java - How to pass unsigned bytes to SecretKeySpec()? -

i need use java's secretkeyspec() array of numbers greater 127. if following: new byte[] { (byte)0xd9, (byte)0xdf, (byte)0x85 } the numbers converted bytes , they'll negative. of course can & them 0xff , save them in short array , save value, won't able pass array secretkeyspec() , because receives bytes[] array. any ideas? this rendering issue. secretkeyspec works byte array, , have no problem constructing byte array. question how represent large (>127) integers java bytes, or equivalently, mean '217' byte. you use whatever mapping want, java has pretty natural choice - convert integer byte, use cast, (byte)i , , convert back, use byte.tounsignedint(b) . can see, recovers original values: public static void main( string[] args ) { (int count = 0; count<256; count++){ system.out.println(count+" : "+(byte)count+" => "+byte.tounsignedint((byte)count)); } }

git - Merge changes from grandchild branch without touching direct child? -

we had branch a . needed improve functionality b planning on working on using function a . branched out a branch b . then, wanted improve specific functionality in a qualitative boost in performance of b branched out b , created c . my question is, what's best way changes add in c , put them in a without changes b . should use cherry pick in cases this? there superior way accomplish this? result in messy error in git? one cleaner way branch c a , not b . , merge c a , rebase b on top of a (or rebase b on top of c , while c isn't yet merged on a ). if branch c b , cherry-pick, might have issues later on when merge b (which might include c enhancement) a. because cherry-picking can introduce duplicate commits and/or functional dependencies . cherry-pick 1 branch when know never merge "one branch" anyway.

mysql - retrieve row based of indirect referencing -

i'm having trouble query. based on primary key, have use foreign key in same tuple/row access table foreign key primary key. i have no idea how approach since can't save foreign key in variable example. tldr query this; 1. use user input search primary key 2. requested row 3. use column in row search table 4. second requested row 5. return contents 2 rows requested. select * table1 table1.primarykey = 'userinput' union select * table2, table1 table1.foreignkey = table2.foreignkey; this have far, doesn't work. illustrates point. usually 2 queries, i'd rather in one. what using join s ? select * table2 join table1 on table1.foreignkey = table2.foreignkey table1.primarykey = 'userinput' or, way be: select * table1, table2 table1.foreignkey = table2.foreignkey , table1.primarykey = 'userinput'

How to create new functions for String class in Ruby? -

i want check type of strings encounter: class string def is_i? /\a[-+]?\d+\z/ === self end def is_path? pn = pathname.new(self) pn.directory? end end def check(key) puts case key when is_i? puts "could number" when is_path? puts "this path" else puts "ok" end end when run check("1345425") following error: undefined method `is_i?' main:object (nomethoderror) what should correct it? you have defined functions on string instance, hence: def check(key) puts case when key.is_i? "could number" when key.is_path? "this path" else "ok" end end or def check(key) puts case key when ->(s) { s.is_i? } "could number" when ->(s) { s.is_path? } "this path" else

multiplication - Prolog, check divisibility in Peano arithmetic -

i need check if first given term (for example s(s(nul)) (or 2)) dividable second term, (for example s(nul) (or 1)). what want multiply given term 2 , check if term smaller or equal other term (if equal - problem solved). so far got this: checkingifdividable(x,x). checkingifdividable(x,y) :- x > y, multiplication(x,y). /* multiplication 2 should occur here. can't figure out. solution not work!*/ multiplication(y):- yy y * 2, checkingifdividable(x,yy). i can't seem figure out how multiply term 2. ideas? if a = n*b, n > 0 , a = n*b = (1+m)*b = b + m*b, m >= 0 . so if a dividable b , , a = b+x , x dividable b . in peano encoding, n = 1+m written n = s(m) . take here.

postgresql - Using postgres-simple, how do I get multiple parameters from a row -

i trying make basic query postgresql-simple 0.5.0.1 , 0.5.1.0. familiar content in postgresql-simple query error , different error message. data sensorrow = sensorrow int string string deriving show instance fromrow sensorrow fromrow = sensorrow <$> field <*> field <*> field *databaseintegrationspec> db <- connectpostgresql dbstring *databaseintegrationspec> r <- query_ db "select (id, name, token) sensor" :: io [sensorrow] *** exception: incompatible {errsqltype = "record", errsqltableoid = nothing, errsqlfield = "row", errhaskelltype = "int", errmessage = "types incompatible"} *databaseintegrationspec> r <- query_ db "select (id, name, token) sensor" :: io [(int, string, string)] *** exception: incompatible {errsqltype = "record", errsqltableoid = nothing, errsqlfield = "row", errhaskelltype = "int", errmessage = "types incompatible"} *da

numpy - Printing data Python -

i have following data id x y name 312 33.76 55.2 aaa 312 33.76 55.2 bbb 443 66.33 11.5 ccc 686 44.55 ddd 222 44.6 eee 423 88.3 23.6 fff i had make popularity = dict(counter(data['id'])) print "id\tpopularity" k, v in popularity.items(): print '{0:.0f}\t{1}'.format(k,v) to find out popularity and had find out unique id using code uni_id = np.unique(data['id']) now want print out unique id x , y , popularity not name , need ignore column without x or y how can combine code ? !

vba - Fetch all mails from inbox with pr_last_verb_executed into Excel sheet -

i want fetch outlook inbox emails excel sheet additional columns having data this mail replied on or this mail forwarded to here code have done far dim folder outlook.mapifolder dim irow integer mailboxname = 'mailbox name goes here pst_folder_name = "inbox" set folder = outlook.session.pickfolder 'folders(mailboxname).folders(pst_folder_name) if folder = "" msgbox "invalid data in input" goto end_lbl1: end if folder.items.sort "[receivedtime]", false limitdatetimevalue = 'date limit cellno = 2 irow = 1 folder.items.count on error resume next if folder.items.item(irow).receivedtime > limitdatetimevalue 'cellno = 2 on error resume next thisworkbook.sheets("inbox").range("a2").select fullsubjectline = folder.items.item(irow).subject if instr(1, fullsubjectline, "fe:", vbtextcompare) > 0 or instr(1, fullsubjectline, "fw:", vbtextcompare) >

java - Android SQLite cursor returns 33 results, but debug only outputs 17 -

hi folks i've got strange cade. i'm trying debug sqlite db in app. if query select * table 33 results, if iterate on cursor ends @ result #17. here's debug class (the method in question public static void writetofile(cursor cursor, string query , string tables, string uri) ) : package com.s2u.android.ps; import java.io.file; import java.io.filewriter; import java.io.printwriter; import java.text.simpledateformat; import java.util.arraylist; import java.util.calendar; import java.util.list; import android.content.context; import android.database.cursor; import android.database.sqlite.sqlitedatabase; import android.os.environment; import android.util.log; import com.s2u.android.ps.bo.app; import com.s2u.android.ps.bo.appmember; import com.s2u.android.ps.datamodel.databasemanager; import com.s2u.android.ps.networkapis.androidlog; import com.s2u.android.ps.networkapis.appconfig; public class debugtofile { private static string tag = "debugtofile"