Bitcoin Forum
July 11, 2024, 12:46:19 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Warning: One or more bitcointalk.org users have reported that they strongly believe that the creator of this topic is a scammer. (Login to see the detailed trust ratings.) While the bitcointalk.org administration does not verify such claims, you should proceed with extreme caution.
Pages: [1]
  Print  
Author Topic: I'm here to help you guys Please pass queries regarding Java and Web Development  (Read 625 times)
avw1982 (OP)
Hero Member
*****
Offline Offline

Activity: 644
Merit: 500



View Profile
November 21, 2015, 04:04:42 PM
 #1

I am here to help you, Ask your questions freely and we will discuss about it. from basic to expert level!!!
Patatas
Legendary
*
Offline Offline

Activity: 1750
Merit: 1115

Providing AI/ChatGpt Services - PM!


View Profile
November 21, 2015, 07:59:13 PM
 #2

Hi since you're offering the service I would like to ask a question I have been breaking my head for hours .
How can I parse json data and represent the objects in from of a list style using JavaScript ? The json file is on a remote server and I'm using $http method to call the file ,I'm able to parse the data but not able to re present in the list style .
avw1982 (OP)
Hero Member
*****
Offline Offline

Activity: 644
Merit: 500



View Profile
November 22, 2015, 05:31:40 PM
 #3

Hi since you're offering the service I would like to ask a question I have been breaking my head for hours .
How can I parse json data and represent the objects in from of a list style using JavaScript ? The json file is on a remote server and I'm using $http method to call the file ,I'm able to parse the data but not able to re present in the list style .

Just I am giving example for you.

var obj=jQuery.parseJSON( '{ "name": "avw1982" }' );
alert( obj.name === "avw1982");

JSON standard does not permit control characters such as tab or newline...
xeryan
Sr. Member
****
Offline Offline

Activity: 337
Merit: 250

HTML5/Node.js/PHP developer


View Profile
November 22, 2015, 05:34:13 PM
 #4

Hi since you're offering the service I would like to ask a question I have been breaking my head for hours .
How can I parse json data and represent the objects in from of a list style using JavaScript ?
Quote from: OP
I'm here to help you guys Please pass queries regarding Java and Web Development
@Pat: You should first understand the difference between Java and Javascript.
Patatas
Legendary
*
Offline Offline

Activity: 1750
Merit: 1115

Providing AI/ChatGpt Services - PM!


View Profile
November 22, 2015, 07:13:47 PM
 #5

Hi since you're offering the service I would like to ask a question I have been breaking my head for hours .
How can I parse json data and represent the objects in from of a list style using JavaScript ?
Quote from: OP
I'm here to help you guys Please pass queries regarding Java and Web Development
@Pat: You should first understand the difference between Java and Javascript.
The OP doesn't seem to have any problems with the question. In fact he appreciated it and answered .Which part of this post you are contributing to rather than critising my knowledge of java and JavaScript's ?Sure I would appreciate your post had it been imparting quality suggestions or knowledge .If you have to say something make it look productive or stop spamming the threads as you're doing in your previous posts .
avw1982 (OP)
Hero Member
*****
Offline Offline

Activity: 644
Merit: 500



View Profile
November 23, 2015, 06:11:49 PM
 #6

Hi since you're offering the service I would like to ask a question I have been breaking my head for hours .
How can I parse json data and represent the objects in from of a list style using JavaScript ?
Quote from: OP
I'm here to help you guys Please pass queries regarding Java and Web Development
@Pat: You should first understand the difference between Java and Javascript.
The OP doesn't seem to have any problems with the question. In fact he appreciated it and answered .Which part of this post you are contributing to rather than critising my knowledge of java and JavaScript's ?Sure I would appreciate your post had it been imparting quality suggestions or knowledge .If you have to say something make it look productive or stop spamming the threads as you're doing in your previous posts .

Cool Bro... Take it easy, Have you understood the example which I gave Is it fine for your clarification? If not means please let me know dude. I ll try to help you as much I can.
avw1982 (OP)
Hero Member
*****
Offline Offline

Activity: 644
Merit: 500



View Profile
November 23, 2015, 07:29:36 PM
 #7

My question: What is the best way to use python code inside Java code (more specifically, Android)?, a colleague is working on an app that should use GNU Radio library (which works with both c++ and python) and we would like to evaluate alternatives (there is already an Android version of GNU Radio, but it seems a bit incomplete).

Hi since you're offering the service I would like to ask a question I have been breaking my head for hours .
How can I parse json data and represent the objects in from of a list style using JavaScript ?
Quote from: OP
I'm here to help you guys Please pass queries regarding Java and Web Development
@Pat: You should first understand the difference between Java and Javascript.

"...regarding Java and Web Development", it is possible to argue about the meaning of the title. The OP could have meant either "Web Development in Java" or "Java and Web Development in general" (some people would recommend using an Oxford Comma if you wanted the second meaning, but, as far as I know, it is not mandatory, so either could be).
2 to 3 ways we have dude. previously in older version java we used some steps but nowadays in jython, normally people use to develop android platform using in SL4A

import android
droid = android.Android()
result = droid.makeToast('Hello, world!')

In every file used have have import file android.py python
Try this dude if this not fine for also let me know dude
Marbit
Hero Member
*****
Offline Offline

Activity: 686
Merit: 500


View Profile
November 30, 2015, 08:19:14 AM
 #8

Hey can you compile a Java based wallet for Bitcoin and what code will you use in it? can you give  a sample of a module like the java code for connecting wallet to blockchain.

Best Regards
avw1982 (OP)
Hero Member
*****
Offline Offline

Activity: 644
Merit: 500



View Profile
December 07, 2015, 06:51:31 PM
 #9

Hey can you compile a Java based wallet for Bitcoin and what code will you use in it? can you give  a sample of a module like the java code for connecting wallet to blockchain.

Best Regards

Yup we can do through the concept bitcoinj, and you can acheive in wallet connect as well as you can trace the wallet's transactions too.

Please find it...

import java.math.BigInteger;

import com.google.bitcoin.core.*;
import com.google.bitcoin.core.Wallet.SendRequest;
import com.google.bitcoin.params.UnitTestParams;
import com.google.bitcoin.store.*;
import com.google.bitcoin.utils.TestUtils;

public class MyProgram {
   
   public static void main(String[] args) throws Exception {
        Wallet wallet = new FakeWallet();
       
        System.out.println("Your wallet:\n"+wallet);
      
        ECKey toDestination = new ECKey();
        Address destination = toDestination.toAddress(wallet.getNetworkParameters());
        //You could also create an address like this in prod (but not here in test):
       //Address destination = new Address(wallet.getNetworkParameters(), "1JwSSubhmg6iPtRjtyqhUYYH7bZg3Lfy1T");
       
      SendRequest request = SendRequest.to(destination, BigInteger.valueOf(2000L));
      
      //Here are some examples that could change the transaction fee
      Wallet.SendRequest.DEFAULT_FEE_PER_KB = BigInteger.ZERO;
      request.ensureMinRequiredFee = false;
      request.fee = BigInteger.ZERO;
      request.feePerKb = BigInteger.ZERO;
      
      //Create the transaction
      Transaction transaction = wallet.sendCoinsOffline(request);
      
      System.out.println("The transaction:\n"+transaction);
   }
   
   static class FakeWallet extends Wallet {
      //A fake wallet that does not run on the real bitcoin network
      static NetworkParameters params = UnitTestParams.get();
      private static final long serialVersionUID = 1L;
      private ECKey myKey;
       private Address myAddress;
      private BlockStore blockStore;
      public FakeWallet() throws Exception {
         super(params);
         myKey = new ECKey();
           myAddress = myKey.toAddress(params);
           addKey(myKey);
           blockStore = new MemoryBlockStore(params);
           receiveFakeCoins(blockStore, BigInteger.valueOf(100000000), this, myAddress);
           //You could also create a blockchain = new BlockChain(params, wallet, blockStore);
      }
      public static void receiveFakeCoins(BlockStore blockStore, BigInteger amount, Wallet wallet, Address toAddress) throws Exception {
         Transaction tx = TestUtils.createFakeTx(wallet.getNetworkParameters(), amount, toAddress);
         TestUtils.BlockPair bp = TestUtils.createFakeBlock(blockStore, tx);
         wallet.receiveFromBlock(tx, bp.storedBlock, AbstractBlockChain.NewBlockType.BEST_CHAIN, 0);
         wallet.notifyNewBestBlock(bp.storedBlock);
      }
   }
}


This I created with fake Btc address and with fake details. But this is the coding format and functions for Wallet transaction and wallet connection In Java platform medium.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!