With Apple's bombshell announcement last week blaming weak fourth-quarter earnings on slow sales in China, what's really going on in the world's second-largest economy? 

In a vast country of 1.4 billion people, it can be pretty hard to tell. But in his letter to investors and a subsequent interview, Apple (AAPL) - Get Report CEO Tim Cook made his perspective clear: China's slowing economy in the back half of 2018, made worse by the roiling trade tensions between the U.S. and China, led to dramatically weaker iPhone sales in the country than both Apple and Wall Street had hoped for. In the quarter covering the crucial holiday period, Apple reduced its revenue outlook by at least $9 billion compared to its original guidance -- and since then, its shares are down about 7%.

In the days since, analysts and observers have sought to parse out the meaning of Apple's bad news. Accounting for 18% of its revenue, according to Factset, China is Apple's second-largest consumer market as well as its manufacturing base. Certainly the signs of a slumping economy and diminished consumer confidence in China are plentiful, as recently seen in weak guidance from  Chinese retail giants like Alibaba(BABA) - Get Report  which referenced the trade war as further dragging down consumer spending. 

Anecdotally, however, some Apple onlookers have wondered whether Trump's trade crusade and rhetoric towards China is also simply souring Chinese consumers on American brands. Stanley Chao, a brand consultant who travels frequently to China, told TheStreet that anti-U.S. sentiment in the country has greatly intensified. "Trump is in the news every day in China, his negative words on China are front page news," Chao said. "The average Chinese consumer is saying, 'Why should I buy a U.S. product if the U.S. hates us so much? There are so many options out there now -- Huawei, Samsung, etc. so I'll just buy one of those and not support the U.S.'"

In an interview with CNBC, Tim Cook seemingly dismissed the idea that antipathy towards Apple, one of the most recognizable American brands in the world, is affecting iPhone sales in China. Asked specifically about whether anti-Apple sentiment was coming into play, Cook said: "There are reports, sort of sporadic reports, about somebody talking about not buying our products because we're American, maybe a little bit on social media, maybe a guy standing in front of a store or something. My personal sense is that this is small. Keep in mind that China's not monolithic, just like America's not monolithic."

Still, if any Chinese consumers are shying away from Apple in favor of homegrown brands, there are other reasons why this might be the case.

"Chinese brands have gotten very good," added mobile industry analyst Rene Ritchie, who also edits the Apple-focused blog iMore. "Previously there were great budget alternatives, but now Huawei is making very good flagship phones, and there's probably a sense of patriotism out there as well. But, you're also getting a very good phone."

It's difficult to know whether Chinese consumers have switched to homegrown smartphones in large numbers, compared to iPhones. But it's worth noting that Huawei -- the largest phonemaker in China, and now second-largest in the world behind Samsung -- has surged in unit shipments in recent quarters, and also earns about 98% of its revenue in China according to Factset.

According to Strategy Analytics, Huawei shipped 51.8 million smartphones in the third quarter of 2018, representing a year-over-year increase of 32%, compared to the 46.9 million iPhones Apple shipped during the same period. Some of Huawei's highest-end models are also comparably priced to iPhones. But by and large, they also may offer a better value for cost-conscious Chinese buyers. For example, the top-line Huawei Mate 20 Pro sells for the equivalent of about $790 in China, whereas the entry-level iPhone XR will still run a Chinese buyer about $950.

Chinese consumers also have an easier time switching phones, Ritchie added. Because of the ubiquity of Tencent's (TCEHY) WeChat -- a platform that weaves messaging and social media with a host of other services like payments and games -- Chinese users also aren't as entrenched into one operating system over another, and can switch phones more easily. "It means if you have an iPhone and switch to Android, you can get up and running on something you're already familiar with," he said.

Apple's revenue outlook in China isn't completely dire, however. As some analysts have noted, Chinese consumers install and use more apps than Americans on average, so as Apple continues to emphasize services like the App Store and iTunes over phone sales, there could be more positive returns coming from China eventually. 

Until then it looks like Apple is fighting its own battles in China, on multiple fronts. 

Apple is a holding in Jim Cramer's Action Alerts PLUS member club. Want to be alerted before Jim Cramer buys or sells AAPL? Learn more now.