• Breaking News

    Wednesday, December 16, 2020

    Android Dev - Parsing Nested JSON Using Moshi and Adapter

    Android Dev - Parsing Nested JSON Using Moshi and Adapter


    Parsing Nested JSON Using Moshi and Adapter

    Posted: 16 Dec 2020 04:19 AM PST

    Question about moshi and parsing deep nested json.

    This is the sample json

    { sucess: true filters: "" instrument: { details: { controlNumber: "123456", localName: "Test", alternateName: "Test2" diameter: "" dimension: "1x1" english: { englishName: "Hi ho" } } } } 

    Instead of the basic step of creating a data class for Instrument, Detail and English, it looks like creating adapters make this more flexible. I have looked into adapters but somehow I am confused with how it should be created. I have read samples that require separate adapter class for Instrument, Detail and English properties.

    If this is the case, what is different from just using data classes straight away?

    I only want to get the values inside the Detail and Files key so instead of creating each data class for nested properties, i wish to get only the output of the detail properties.

    I thought instrument.detail.[keyname] was the way to go but it is not. Thoughts?

    submitted by /u/chitgoks
    [link] [comments]

    How I Learned to Manage My Small Team of Devs and So Can You

    Posted: 16 Dec 2020 05:19 AM PST

    Peer translations

    Posted: 16 Dec 2020 05:47 AM PST

    Hello fellow Android developers!
    I propose to translate strings from your apps for free.

    I can translate from English to Russian + Ukrainian languages (these are my 2 native languages).

    In exchange I will kindly ask you to translate strings from my apps to other languages (English to German or Spanish, for example).

    Please comment below if you know some resource which already provides such "peer" translation exchange services, or contact me for collaboration or more info.

    submitted by /u/keaukraine
    [link] [comments]

    Jetpack Compose — Before and after

    Posted: 15 Dec 2020 02:01 PM PST

    Magnify the touched part of a view android

    Posted: 16 Dec 2020 01:32 AM PST

    Guys i am trying to achieve this magnifying feature that I want to use with my custom view which gives functionality of image free hand crop to user.

    I don't want to use getDrawingCache() as it is deprecated.

    Any help would be appreciated thanks.

    submitted by /u/droidexpress
    [link] [comments]

    Multiplayer game without third party solutions for client <-> server communication

    Posted: 16 Dec 2020 07:52 AM PST

    Hei :),

    I'd like to create a multiplayer game for Android where users are grouped together randomly to play a board game. I'd like to create the infrastructure by myself, without solutions like Firebase and what not. The reason is because I'd like to learn more about infrastructure in general: networking, designing the server-client messages communication, board game updates at any given move etc.

    I've spent all day googling for tutorials for this (good practices, similar projects etc.) and
    shockingly I could not find anything useful. I only found something similar done in Firebase.

    I would be very grateful if you could give me some advises / tutorials!

    submitted by /u/hopefullyoneluckyguy
    [link] [comments]

    So confused. What is this icon in my status bar on my Samsung galaxy s10e????

    Posted: 16 Dec 2020 07:27 AM PST

    Autotests on Android. The entire picture

    Posted: 15 Dec 2020 10:37 PM PST

    The post.
    Welcome to discuss!

    submitted by /u/eugene_matsyuk
    [link] [comments]

    Open source app license issues

    Posted: 15 Dec 2020 04:05 PM PST

    So I have a fairly popular open source app under the MPL 2.0 license (a fork of an existing app), and a company recently came along and forked my app. That company also bought the brand name of a relatively well known app in the category.

    They have removed any reference to me in the app, have removed the open source licenses section and actively try to cover up the fact that it's a fork. If anyone asks on their community chat, their messages are deleted. Someone who uses my app sent a chat message directly asking if the app was a fork and they were ignored. They've also added ads to the app and have entered competitions with it framing it as an app they built themselves which is the future of the category.

    Their app is open source too, and whenever I commit and add something to my app, they add the exact same commit to theirs, but with any license notices removed. Some people who use my app spammed on the community chat for the other app as well, and I messaged the developer of the other app apologizing, but also asking to speak with him about my concerns. I was accused of being 'racist' and deliberately trying to spam his chat and destroy his reputation. I was also sent threatening messages over a Reddit post made by someone else. He told me he'd stop if I added an option to export app data from my app to his.

    I'm at a complete loss and I have no motivation to work on my app anymore as they are gathering a large userbase due to the name and seemingly have a fair amount of money behind them. I've even been accused of copying their app by some people.

    If anyone has any advice or has been in a similar situation, it'd be a massive help. There might be nothing I can do, or maybe it's to be expected from open source, but I don't see anything better about their app at all yet mine's probably going to be overshadowed by it despite the massive work I put into it)

    submitted by /u/373throwaway373
    [link] [comments]

    Developer console - Store & Conversion analysis are completely wrong (for years, for all my apps) - anybody else has the same problem?

    Posted: 15 Dec 2020 08:48 PM PST

    I have a problem with conversion rates of my app - those stats are just completely wrong...For years. For all my apps. And they have never been right...

    This is screenshot from my console. It says I am 17% below average, deep in the worst 25% percentile.

    But how the hell I can be that bad, I am above average (my peers median) in every single country in top 20 as you can see here in this screenshot (it is the same for all remaining countries, but I didnt want to post too long list...)

    These are my observations:

    • I noticed its 2 countries which skew the stats - JAPAN and SOUTH KOREA. These 2 countries seems to have by far highest visitors numbers and by far worst conversion rate, which deforms my global rate. But I believe there is a bug in console, because:
      • a) it is very odd, borderline impossible, that all my apps, since day 1, are by far most popular in Japan and South Korea (I am based in EU, and my apps are not translated to KR nor JP). It is very unrealistic, that all my apps have exactly the same statistical "bug"
      • b) even if it was right (let's say, it is) - even in these 2 countries as you can see, I am above average, so how can I be so much below average globally?
      • c) if I remove JP and KO from stats, my conversion rate goes to 30%. Which seems to be about right, weighted average from list and makes sense. So far so good, but - how can be the average of my competitors 40%? I am already above average in every country, it is hard to believe all my competitors are also above average (and even more than me), so...if all of them are above average, then who is average?

    I simply don't get this "Google math", it is wrong on multiple levels...Anybody else has the same problem?

    submitted by /u/throwaway41142095
    [link] [comments]

    What's the lowest CPI (cost per install) you've ever had?

    Posted: 16 Dec 2020 04:38 AM PST

    I'm currently at $0.02 USD So about 50 installs per $1 USD

    I'm not getting any money from my current users though

    But I'm hoping to "ignite" my game by gaining traffic from low cost countries and hopefully in the long run getting organic downloads from Europe and the US

    submitted by /u/No-Establishment4313
    [link] [comments]

    I'm at $0.02 per install on Google Ads

    Posted: 16 Dec 2020 04:35 AM PST

    I'm currently advertising my highly rated game (4.7) in the middle east

    I know the culture, so the game is very relevant to people.

    I'm advertising all across the middle east and average CPI is at around $0.02 that's 2 cents per install using video on Google Ads

    Was hoping to increase organic downloads in Arab gulf countries by advertising in jordan

    Advertising in gulf countries is expensive and I can't afford it now

    You guys think this is a good strategy?

    submitted by /u/No-Establishment4313
    [link] [comments]

    Hey @AWSAmplify, Is this food?

    Posted: 15 Dec 2020 09:46 PM PST

    Midlife crisis for an Android Dev

    Posted: 15 Dec 2020 10:10 AM PST

    Call it a midlife crisis. Been an Android Dev for over 6 years. What else can I learn to keep the creative juices flowing? What can help with career growth? Share your story.

    submitted by /u/anilmaddala
    [link] [comments]

    Getting the correct URI from Intent.ACTION_GET_CONTENT

    Posted: 15 Dec 2020 08:31 PM PST

    Hello, I have problems regarding the real path of an image or video selected by an Intent.ACTION_GET_CONTENT. I do use a method provided by someone from stackoverflow and it converts data.getData() from something like "content://media/46381" to "/storage/emulated/0/WhatsApp/Media/WhatsApp Video/VID-654783.mp4" as an example. When I try to call this URI by VideoView.setVideoURI(Uri.parse(path)); I always get the error message that the video cannot be played. This has nothing to do with the video format or anything I was able to call the media already via other methods but always had problems with the correct uri. Could someone please give me some insights about how the paths work in android? I was pretty sure the path I get would be correct.

    submitted by /u/duck_mopsi
    [link] [comments]

    Top 10 Android Libraries and Tools for Android Development.

    Posted: 16 Dec 2020 02:02 AM PST

    External camera to VR viewports?

    Posted: 15 Dec 2020 06:27 PM PST

    I want to take an external camera and display it through my Gear VR with no accelerometer or gyroscope functionality. I have the Cardboard VR part showing the demo. I have the USB camera showing video. I just need to bring the 2 views together. Is there an existing solution I've missed or maybe some guidance on where to connect the 2 projects?

    submitted by /u/Circa_Lucid
    [link] [comments]

    What are some not so obvious tips before building a new app that has to be released?

    Posted: 15 Dec 2020 08:58 AM PST

    After so many stories (negative and positive) we saw here, let's assume someone starts now building a new app that has to be released in the store. What are the not so obvious tips you would advise them? Not only in terms of development but also for publishing and whatever else that is not very well known.

    submitted by /u/gts-13
    [link] [comments]

    Realeasing First App Checklist?

    Posted: 15 Dec 2020 10:24 AM PST

    I am close to being done with my first MVP and want to release a beta version on the Google Playstore! What are some things I should consider before releasing?

    Any additional security measures other than firebase rules? Do I need to register myself as a business (any links if so)? Any legal things to do? I am a walmart affiliate and plan to generate revenue via their affiliate program and links.

    Any and all advice is appreciated!

    submitted by /u/rickhouse
    [link] [comments]

    Can you use the name of famous people on apps without their permission?

    Posted: 15 Dec 2020 03:35 PM PST

    I'm learning to programming and wanted to make a quiz app about a topic, like, who said this? And the answer is the name of a famous X. Imagine that at the end I end up with a decent app and want to put some adds and upload it to the play store.

    Would I be allowed to do that? Not using their names for announcing my app or anything, just naming them in the app.

    submitted by /u/landismo
    [link] [comments]

    Monetize app with other service that AdMob (ads) and gpdr compliant

    Posted: 15 Dec 2020 12:36 PM PST

    Hello,

    Do you know please how to monetize (Ads) a Cordova iOS/Android/Windows 10/Huawei app ?

    Not AdMob because cookies are used so not ads display if user refuse TCF 2 consent form (gdpr)

    Best regards

    submitted by /u/alex57600
    [link] [comments]

    Samsung Galaxy A3 (2017): I Can't Change Change Album Art...

    Posted: 15 Dec 2020 06:21 PM PST

    For one artist (Shampoo), there are 3 songs that are in a separate album (it has a black album art). If I go to the songs that have the correct album art, and go to the 3 dots next to the song and click 'album', all the songs with the correct album are in there.

    Here is something even weirder, if I do the same thing to those 3 songs that don't have correct album art, it shows every song on my phone, starting with the Grease movie soundtrack.

    I can't change the album art for Shampoo, no matter what.If you can figure it out, I will literally pay you, because I've been through every solution known and I'm telling you it is not possible. I've no problem in the past, and I've no problem with other songs.

    Most of the songs by this artist were downloaded via Google Play.

    I can't figure out what is with this artist and with those 3 songs.

    I can't even change the other songs the the same thumbnail, which is the same as the rest of the songs on my phone, beside Shampoo.I've added the album artist via EasyTag; a Linux programme; something I always used.Here's what I tried so far:

    Deleting cache

    deleting cache to Samsung Music app

    Deleting thumbnails

    Restarting phone

    Deleting and copying from my computer

    Deleting and copying from another phone

    Wiping the phone and SD card and starting over, only transferring over apps from backup, that is all.

    Downloading this selecting songs from Youtube

    Ripping those selected songs from CDWiping the metadata and adding in the song, artist, and album art.

    I tried .wav, it doesn't work, nor does .aac, it has to be mp3.

    Changing the name of the songs.Changing the name or the artist.

    For some reason, if I copy the songs from my other phone, or I guess when they're on phone storage instead of the SD card, the album art shows up on all the Shampoo's songs, but it's still divided into two albums.

    submitted by /u/HelloRainClouds
    [link] [comments]

    No comments:

    Post a Comment