首页 \ 问答 \ 如何为eclipse Kepler安装SWT(How to install SWT for eclipse Kepler)

如何为eclipse Kepler安装SWT(How to install SWT for eclipse Kepler)

我最近下载了eclipse Kepler来学习使用SWT,我还下载了SWT zip文件夹。 eclipse网站上的说明指出我应该将zip文件夹导入到Existing Projects into Workspace 。 我已经完成了这个,但是在Projects表单字段上没有显示任何项目,我从早上开始使用谷歌搜索获取有关如何在Eclipse Kepler上安装SWT信息,但我没有找到任何帮助。

我需要帮助,因为我面对的是一个需要丰富外观和感觉的项目。 所有回复将不胜感激。 谢谢大家。


I recently downloaded eclipse Kepler to learn to use SWT, I also downloaded the SWT zip folder. The instructions on eclipse web site states that I should import the zip folder to Existing Projects into Workspace. I have done this, but no project shows on the Projects form field, I have been googling since morning to get info on how to install SWT on Eclipse Kepler but I have not found any help.

Please I need help on this, as I am faced with a project that needs rich look and feel. All replies would be greatly appreciated. Thanks to all.


原文:https://stackoverflow.com/questions/18983022
更新时间:2023-10-20 13:10

最满意答案

您的代码看起来没有什么可以突破while循环。 想到的一种方法是将变量设置为空列表,然后使用每条推文将其附加到列表中。

foo = []
for status in tweepy.Cursor(api.search, q=hashtag).items(2):
   tweet = status.text
   foo.append(tweet)
print foo

当然,这将打印一个列表。 如果您想要一个字符串,请使用字符串join()方法。 将最后一行代码调整为如下所示:

bar = ' '.join(foo)
print bar

Your code looks like there's nothing to break out of the while loop. One method that comes to mind is to set a variable to an empty list and then with each tweet, append that to the list.

foo = []
for status in tweepy.Cursor(api.search, q=hashtag).items(2):
   tweet = status.text
   foo.append(tweet)
print foo

Of course, this will print a list. If you want a string instead, use the string join() method. Adjust the last line of code to look like this:

bar = ' '.join(foo)
print bar

相关问答

更多
  • 当你使用地点时:这是用户发布推文时的位置。 在你的情况下,结果要么是孟买,要么是孟买一个更具体的地方,比如邻居。 $ oksocial 'https://api.twitter.com/1.1/search/tweets.json?q=place%3A7929cea6bd5b32bd' | jq '.statuses[].place.full_name' "Mumbai, India" "Mumbai, India" "Mumbai, India" "Mumbai, India" "Mumbai, Indi ...
  • 正如@balki所说,这是因为在这种模式中每个JSON对象都有空行: 1 JSON Object 2 empty line 3 JSON Object 4 empty line 所以我从以下问题中解决了删除文件(python)中的特定行并将其更改为擦除空行的问题,如下所示: def erase_empty_lines(file_name): file = open(file_name, 'r') lines = file.readlines() file.close() ...
  • 我正在为您发布我的实时代码。希望它适合您。 SearchTerm是search.Below方法的关键字,它将在String中返回一个json响应。 如果你想要gson序列化类。 我会为你提供 ProgressDialog pd; new DownloadTwitterTask().execute(keyword); private class DownloadTwitterTask extends AsyncTask { ...
  • 你想要实现的目标实际上非常简单。 Tweetinvi与Newtonsoft.Json.NET一起自动安装。 您可以使用Tweetinvi 1.0支持序列化,如下所示: var tweets = Timeline.GetHomeTimeline(); // Store 1 array var json = JsonConvert.SerializeObject(tweets.Select(x => x.TweetDTO)); // Or iterate foreach (var tweet in twee ...
  • 您将搜索结果作为整体附加到searled_tweets列表中,以便现在由单个项目组成。 你应该完全删除searled_tweets的东西,只是将new_tweets传递给你的函数。 You're appending the search result as a whole to the searched_tweets list, so that now consists of a single item. You should remove the searched_tweets stuff altoget ...
  • 以下是用户在LINQ to Twitter中查找的方式: var users = (from user in twitterCtx.User where user.Type == UserType.Lookup && user.ScreenName == "cinek24,blaba" select user) .ToList(); us ...
  • 您的代码看起来没有什么可以突破while循环。 想到的一种方法是将变量设置为空列表,然后使用每条推文将其附加到列表中。 foo = [] for status in tweepy.Cursor(api.search, q=hashtag).items(2): tweet = status.text foo.append(tweet) print foo 当然,这将打印一个列表。 如果您想要一个字符串,请使用字符串join()方法。 将最后一行代码调整为如下所示: bar = ' '.join( ...
  • 问题在于这一行: tweets= tweepy.Cursor(api.search,q=[searchTerms], 您所做的是创建一个包含列表的列表。 看看这段代码: searchTerms = ["#Xfactor", "#Yfactor"] q=[searchTerms] print(searchTerms) >>> ['#Xfactor', '#Yfactor'] print(type(q)) >>> [['#Xfactor', '#Yfactor']] 你要搜索的不是searchTerms ...
  • 你现在可能已经找到了答案,但这也是我一直在努力的事情,经过一段时间后发现了一个简单的解决方案。 以下是我检查坐标的方法,并确定是否将推文数据分配到英国或美国数据库。 后跟[1]或[2]的“coordinates”关键字从推文中获取纬度/经度元数据,并将其与下面一行中指定的边界进行比较。 我希望这有帮助 : ) class CustomStreamListener(tweepy.StreamListener): def check_ukcoords(self, status): if sta ...
  • 不,基本API不允许您在用户时间轴或搜索中返回那么远。 完整档案可作为Twitter的Gnip API之一提供。 No, the basic API doesn't let you go back that far either in a user timeline or in search. The full archive is available as one of Twitter's Gnip APIs.

相关文章

更多

最新问答

更多
  • 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
  • TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
  • 企业安全培训的各项内容
  • 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
  • NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
  • 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
  • 将多个行和可变行移动到列(moving multiple and variable rows to columns)
  • 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
  • Angular $资源不会改变方法(Angular $resource doesn't change method)
  • 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
  • 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
  • Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
  • 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)
  • 是否可以嵌套hazelcast IMaps?(Is it possible to nest hazelcast IMaps? And whick side effects can I expect? Is it a good Idea anyway?)
  • UIViewAnimationOptionRepeat在两个动画之间暂停(UIViewAnimationOptionRepeat pausing in between two animations)
  • 在x-kendo-template中使用Razor查询(Using Razor query within x-kendo-template)
  • 在BeautifulSoup中替换文本而不转义(Replace text without escaping in BeautifulSoup)
  • 如何在存根或模拟不存在的方法时配置Rspec以引发错误?(How can I configure Rspec to raise error when stubbing or mocking non-existing methods?)
  • asp用javascript(asp with javascript)
  • “%()s”在sql查询中的含义是什么?(What does “%()s” means in sql query?)
  • 如何为其编辑的内容提供自定义UITableViewCell上下文?(How to give a custom UITableViewCell context of what it is editing?)
  • c ++十进制到二进制,然后使用操作,然后回到十进制(c++ Decimal to binary, then use operation, then back to decimal)
  • 以编程方式创建视频?(Create videos programmatically?)
  • 无法在BeautifulSoup中正确解析数据(Unable to parse data correctly in BeautifulSoup)
  • webform和mvc的区别 知乎
  • 如何使用wadl2java生成REST服务模板,其中POST / PUT方法具有参数?(How do you generate REST service template with wadl2java where POST/PUT methods have parameters?)
  • 我无法理解我的travis构建有什么问题(I am having trouble understanding what is wrong with my travis build)
  • iOS9 Scope Bar出现在Search Bar后面或旁边(iOS9 Scope Bar appears either behind or beside Search Bar)
  • 为什么开机慢上面还显示;Inetrnet,Explorer
  • 有关调用远程WCF服务的超时问题(Timeout Question about Invoking a Remote WCF Service)