热门标签 | HotTags
当前位置:  开发笔记 > IOS > 正文

iOS仿微信图片分享界面实现代码

这篇文章主要为大家详细介绍了iOS仿微信相册界面翻转过渡动画效果,微信采用界面翻转的过渡动画跳转到评论界面,具有一定的参考价值,感兴趣的小伙伴们可以参考一下

分享功能目前几乎已成为很多app的标配了,其中微信,微博等app的图片分享界面设计的很棒,不仅能够展示缩略图,还可以预览删除。最近我在做一款社交分享app,其中就要实现图文分享功能,于是试着自行实现仿微信分享风格的功能。

核心思想:

主要是使用UICollectionView来动态加载分享图片内容,配合预览页面,实现动态添加和预览删除图片效果。

实现效果:

核心代码如下:

分享界面:

//
// 
 PostTableViewController.h
// 
 NineShare
//
// 
 Created by 张昌伟 on 15/1/26.
// 
 Copyright (c) 2015年 9Studio. All rights reserved.
//
 
#import
 
#import
 "UMSocial.h"
#import
 "YSYPreviewViewController.h"
 
@interface PostTableViewController
 : UITableViewController
 
@property (weak,
nonatomic)
IBOutlet UICollectionView
 *photosCollectionView;
@property (weak,
nonatomic)
IBOutlet UISwitch
 *WeiboSwitch;
@property (weak,
nonatomic)
IBOutlet UISwitch
 *RenrenSwitch;
-
 (IBAction)DoubanSwitched:(id)sender;
-
 (IBAction)RenrenSwitched:(id)sender;
-
 (IBAction)WeiboSwitched:(id)sender;
 
+(void)
 deleteSelectedImage:(NSInteger)
 index;
+(void)
 deleteSelectedImageWithImage:(UIImage*)image;
@end
 

 实现文件

//
// 
 PostTableViewController.m
// 
 NineShare
//
// 
 Created by 张昌伟 on 15/1/26.
// 
 Copyright (c) 2015年 9Studio. All rights reserved.
//
 
#import
 "PostTableViewController.h"
#import
 "NineShareService.h"
static NSMutableArray *currentImages;
@interface PostTableViewController
 ()
@property (weak,
nonatomic)
IBOutlet UITextView
 *shareContent;
-
 (IBAction)postStatus:(id)sender;
-
 (IBAction)cancelPost:(id)sender;
-(void)
 loadSNSStatus;
@property (weak,
nonatomic)
IBOutlet UISwitch
 *DoubanSwitch;
@property (weak,
nonatomic)
IBOutlet UITextView
 *backgroundTextView;
@property NSMutableArray *snsArray;
//@property
 NSMutableArray *photos;
@property NineShareService
 *dataContext;
@property NSMutableDictionary *tempDict;
 
-(void)
 openCamera;
-(void)
 openLibary;
 
@end
 
@implementation PostTableViewController
 
-
 (void)viewDidLoad
 {
 [super viewDidLoad];
 if(currentImages
 ==nil)
 {
 currentImages=[[NSMutableArray alloc]
 init];
 }
 //
 Uncomment the following line to preserve selection between presentations.
 //
 self.clearsSelectiOnOnViewWillAppear= NO;
 
 //
 Uncomment the following line to display an Edit button in the navigation bar for this view controller.
 //
 self.navigationItem.rightBarButtOnItem= self.editButtonItem;
 _dataCOntext=[NineShareService
 getInstance];
 [self loadSNSStatus];
}
-(void)viewWillAppear:(BOOL)animated{
 [_photosCollectionView
 reloadData];
}
-
 (void)didReceiveMemoryWarning
 {
 [super didReceiveMemoryWarning];
 //
 Dispose of any resources that can be recreated.
}
 
-(void)
 loadSNSStatus{
 _snsArray=[NSMutableArray arrayWithContentsOfFile:[[NSBundle mainBundle]
 pathForResource:@"sns" ofType:@"plist"]];
 if(_snsArray.count>0)
 {
 [_WeiboSwitch
 setOn:[_snsArray[0] boolValue] animated:YES];
 [_RenrenSwitch
 setOn:[_snsArray[1] boolValue] animated:YES];
 [_DoubanSwitch
 setOn:[_snsArray[2] boolValue] animated:YES];
 }
}
-(BOOL)textView:(UITextView
 *)textView shouldChangeTextInRange:(NSRange)range
 replacementText:(NSString *)text{
 if(![text
 isEqualToString:@""])
 {
 [_backgroundTextView
 setHidden:YES];
 }
 if([text
 isEqualToString:@""]&&range.length==1&&range.location==0){
 [_backgroundTextView
 setHidden:NO];
 }
 if ([text
 isEqualToString:@"\n"])
 {
 [textView
 resignFirstResponder];
 return NO;
 }
 return YES;
}
-(void)textViewDidBeginEditing:(UITextView
 *)textView
{
 CGRect
 frame = textView.frame;
 int offset
 = frame.origin.y + 32 - (self.view.frame.size.height
 - 216.0);//键盘高度216
 
 NSTimeInterval animatiOnDuration= 0.30f;
 [UIView
 beginAnimations:@"ResizeForKeyboard" context:nil];
 [UIView
 setAnimationDuration:animationDuration];
 
 //将视图的Y坐标向上移动offset个单位,以使下面腾出地方用于软键盘的显示
 if(offset
 > 0)
 self.view.frame
 = CGRectMake(0.0f, -offset, self.view.frame.size.width,
self.view.frame.size.height);
 
 [UIView
 commitAnimations];
}
 
-(void)textViewDidEndEditing:(UITextView
 *)textView{
 self.view.frame
 =CGRectMake(0, 0, self.view.frame.size.width,
self.view.frame.size.height);
}
-(void)collectionView:(UICollectionView
 *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath{
 if(indexPath.row==currentImages.count)
 {
 UIActionSheet
 *action=[[UIActionSheet alloc] initWithTitle:@"选取照片" delegate:self cancelButtonTitle:@"取消" destructiveButtonTitle:nil otherButtonTitles:@"从摄像头选取",
 @"从图片库选择",nil];
 [action
 showInView:self.view];
 }
 else
 {
 [YSYPreviewViewController
 setPreviewImage:currentImages[indexPath.row]];
 [self.navigationController
 pushViewController:[[UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]]
 instantiateViewControllerWithIdentifier:@"PreviewVC"]
 animated:YES];
 }
}
 
-(NSInteger)collectionView:(UICollectionView
 *)collectionView numberOfItemsInSection:(NSInteger)section{
 return currentImages.count==0?1:currentImages.count+1;
}
-(UICollectionViewCell
 *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath{
 UICollectionViewCell
 *cell=[collectionView dequeueReusableCellWithReuseIdentifier:@"collectionCell" forIndexPath:indexPath];
 UIImageView
 *imageView=[[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 50, 50)];
 if(currentImages.count==0||indexPath.row==currentImages.count)
 {
 imageView.image=[UIImage
 imageNamed:@"Add"];
 }
 else{
  
 while ([cell.contentView.subviews
 lastObject] != nil)
 {
  [(UIView*)[cell.contentView.subviews
 lastObject] removeFromSuperview];
 }
 imageView.image=currentImages[indexPath.row];
 }
 
 imageView.cOntentMode=UIViewContentModeScaleAspectFill;
 [cell.contentView
 addSubview:imageView];
 return cell;
}
 
-(void)saveSNSToFile{
 NSString *destPath=[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,
NSUserDomainMask,
YES)
 lastObject];
 if (![[NSFileManager defaultManager]
 fileExistsAtPath:destPath]) {
  NSString *path=[[NSBundle mainBundle]
 pathForResource:@"sns" ofType:@"plist"];
 [[NSFileManager defaultManager]
 copyItemAtPath:path toPath:destPath error:nil];
 }
 
 if(_snsArray==nil)
 _snsArray=[[NSMutableArray alloc]
 init];
 [_snsArray
 removeAllObjects];
 [_snsArray
 addObject:_WeiboSwitch.isOn?@"YES":@"NO"];
 [_snsArray
 addObject:_RenrenSwitch.isOn?@"YES":@"NO"];
 [_snsArray
 addObject:_DoubanSwitch.isOn?@"YES":@"NO"];
 if(_snsArray.count>0)
 {
 [_snsArray
 writeToFile:destPath atomically:YES];
 }
}
 
-
 (IBAction)postStatus:(id)sender
 {
 if(_WeiboSwitch.isOn)
 [[UMSocialDataService
 defaultDataService] postSNSWithTypes:@[UMShareToSina] content:_shareContent.text.length>0?_shareContent.text: @"9Share
 for ios test message" image:currentImages.count==0?nil:currentImages[0]
 location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity
 *response){
  if (response.respOnseCode== UMSResponseCodeSuccess) {
  NSLog(@"分享成功!");
  if(!(_RenrenSwitch.isOn||_DoubanSwitch.isOn))
  {
   [self saveSNSToFile];
   [self dismissViewControllerAnimated:YES completion:nil];
  }
  }
 }];
 if(_RenrenSwitch.isOn)
 [[UMSocialDataService
 defaultDataService] postSNSWithTypes:@[UMShareToRenren] content:_shareContent.text.length>0?_shareContent.text: @"9Share
 for ios test message" image:currentImages.count==0?nil:currentImages[0]
 location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity
 *response){
  if (response.respOnseCode== UMSResponseCodeSuccess) {
  NSLog(@"分享成功!");
  if(!_DoubanSwitch.isOn)
  {
   [self saveSNSToFile];
   [self dismissViewControllerAnimated:YES completion:nil];
  }
  }
 }];
 if(_DoubanSwitch.isOn)
 [[UMSocialDataService
 defaultDataService] postSNSWithTypes:@[UMShareToDouban] content:_shareContent.text.length>0?_shareContent.text: @"9Share
 for ios test message" image:currentImages.count==0?nil:currentImages[0]
 location:nil urlResource:nil presentedController:self completion:^(UMSocialResponseEntity
 *response){
  if (response.respOnseCode== UMSResponseCodeSuccess) {
  NSLog(@"分享成功!");
  [self saveSNSToFile];
  [self dismissViewControllerAnimated:YES completion:nil];
  }
 }];
 
 
}
 
-(void)imagePickerController:(UIImagePickerController
 *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info{
 [picker
 dismissViewControllerAnimated:YES completion:nil];
 UIImage
 *image=[info objectForKey:UIImagePickerControllerOriginalImage];
 NSData *tempData=UIImageJPEGRepresentation(image,
 0.5f);
 image=[UIImage
 imageWithData:tempData];
 if(currentImages
 ==nil)
 {
 currentImages=[[NSMutableArray alloc]
 init];
 }
 [currentImages
 addObject:image];
 [_photosCollectionView
 reloadData];
 //
 [self saveImage:image withName:@""]
}
 
-(void)imagePickerControllerDidCancel:(UIImagePickerController
 *)picker{
 [picker
 dismissViewControllerAnimated:YES completion:nil];
}
-
 (IBAction)cancelPost:(id)sender
 {
 [self dismissViewControllerAnimated:YES completion:nil];
}
 
 
-(void)actionSheet:(UIActionSheet
 *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex{
 
 switch (buttonIndex)
 {
 case 0:
  [self openCamera];
  break;
 case 1:
  [self openLibary];
  break;
  default:
  break;
 }
}
-(void)openCamera{
 //UIImagePickerControllerSourceType
 *type=UIImagePickerControllerSourceTypeCamera;
 if([UIImagePickerController
 isSourceTypeAvailable:UIImagePickerControllerSourceTypeCamera])
 {
  UIImagePickerController
 *picker=[[UIImagePickerController alloc] init];
  picker.delegate=self;
  picker.sourceType=UIImagePickerControllerSourceTypeCamera;
  picker.allowsEditing=YES;
  [self presentViewController:picker
 animated:YES completion:nil];
  
 }
}
-(void)openLibary{
 if([UIImagePickerController
 isSourceTypeAvailable:UIImagePickerControllerSourceTypePhotoLibrary])
 {
 UIImagePickerController
 *picker=[[UIImagePickerController alloc] init];
 picker.delegate=self;
 picker.sourceType=UIImagePickerControllerSourceTypePhotoLibrary;
 picker.allowsEditing=YES;
 [self presentViewController:picker
 animated:YES completion:nil];
  
 }
 
}
-(void)
 saveImage:(UIImage *)image withName:(NSString *)name
{
 NSData *imageData=UIImageJPEGRepresentation(image,
 0.5);
 NSString *path=[NSTemporaryDirectory()
 stringByAppendingPathComponent:name];
 [imageData
 writeToFile:path atomically:YES];
 
}
-
 (IBAction)DoubanSwitched:(id)sender
 {
 if(_DoubanSwitch.isOn){
 if(![UMSocialAccountManager
 isOauthAndTokenNotExpired:UMShareToDouban])
 {
  //进入授权页面
  [UMSocialSnsPlatformManager
 getSocialPlatformWithName:UMShareToDouban].loginClickHandler(self,[UMSocialControllerService
 defaultControllerService],YES,^(UMSocialResponseEntity
 *response){
  if (response.respOnseCode== UMSResponseCodeSuccess) {
   //获取微博用户名、uid、token等
   UMSocialAccountEntity
 *snsAccount = [[UMSocialAccountManager socialAccountDictionary] valueForKey:UMShareToDouban];
   NSLog(@"username
 is %@, uid is %@, token is %@",snsAccount.userName,snsAccount.usid,snsAccount.accessToken);
   //进入你的分享内容编辑页面
   UMSocialAccountEntity
 *doubanAccount = [[UMSocialAccountEntity alloc] initWithPlatformName:UMShareToDouban];
   doubanAccount.usid
 = snsAccount.usid;
   doubanAccount.accessToken
 = snsAccount.accessToken;
   // 
 weiboAccount.openId = @"tencent weibo openId";  //腾讯微博账户必需设置openId
   //同步用户信息
   [UMSocialAccountManager
 postSnsAccount:doubanAccount completion:^(UMSocialResponseEntity *response){
   if (response.respOnseCode== UMSResponseCodeSuccess) {
    //在本地缓存设置得到的账户信息
    [UMSocialAccountManager
 setSnsAccount:doubanAccount];
    //进入你自定义的分享内容编辑页面或者使用我们的内容编辑页面
   }}];
  }
  else {
   [_DoubanSwitch
 setOn:NO animated:YES];
  }
  });
 }
 }
}
 
-
 (IBAction)RenrenSwitched:(id)sender
 {
 if(_DoubanSwitch.isOn)
 {
 if(![UMSocialAccountManager
 isOauthAndTokenNotExpired:UMShareToRenren])
 {
  //进入授权页面
  [UMSocialSnsPlatformManager
 getSocialPlatformWithName:UMShareToRenren].loginClickHandler(self,[UMSocialControllerService
 defaultControllerService],YES,^(UMSocialResponseEntity
 *response){
  if (response.respOnseCode== UMSResponseCodeSuccess) {
   //获取微博用户名、uid、token等
   UMSocialAccountEntity
 *snsAccount = [[UMSocialAccountManager socialAccountDictionary] valueForKey:UMShareToRenren];
   NSLog(@"username
 is %@, uid is %@, token is %@",snsAccount.userName,snsAccount.usid,snsAccount.accessToken);
   //进入你的分享内容编辑页面
   UMSocialAccountEntity
 *renrenAccount = [[UMSocialAccountEntity alloc] initWithPlatformName:UMShareToRenren];
   renrenAccount.usid
 = snsAccount.usid;
   renrenAccount.accessToken
 = snsAccount.accessToken;
   // 
 weiboAccount.openId = @"tencent weibo openId";  //腾讯微博账户必需设置openId
   //同步用户信息
   [UMSocialAccountManager
 postSnsAccount:renrenAccount completion:^(UMSocialResponseEntity *response){
   if (response.respOnseCode== UMSResponseCodeSuccess) {
    //在本地缓存设置得到的账户信息
    [UMSocialAccountManager
 setSnsAccount:renrenAccount];
    //进入你自定义的分享内容编辑页面或者使用我们的内容编辑页面
   }}];
  }
  else{
   [_RenrenSwitch
 setOn:NO animated:YES];
  }
  });
 }
 
 }
}
 
 
-
 (IBAction)WeiboSwitched:(id)sender
 {
 if(_WeiboSwitch.isOn)
 {
 if(![UMSocialAccountManager
 isOauthAndTokenNotExpired:UMShareToSina])
 {
  [UMSocialSnsPlatformManager
 getSocialPlatformWithName:UMShareToSina].loginClickHandler(self,[UMSocialControllerService
 defaultControllerService],YES,^(UMSocialResponseEntity
 *response){
  if(response.respOnseCode==UMSResponseCodeSuccess){
   UMSocialAccountEntity
 *snsAccount=[[UMSocialAccountManager socialAccountDictionary] valueForKey:UMShareToSina];
   UMSocialAccountEntity
 *sinaAccount=[[UMSocialAccountEntity alloc] initWithPlatformName:UMShareToSina];
   //缓存到本地
   sinaAccount.usid
 = snsAccount.usid;
   sinaAccount.accessToken
 = snsAccount.accessToken;
   // 
 weiboAccount.openId = @"tencent weibo openId";  //腾讯微博账户必需设置openId
   //同步用户信息
   [UMSocialAccountManager
 postSnsAccount:sinaAccount completion:^(UMSocialResponseEntity *response){
   if (response.respOnseCode== UMSResponseCodeSuccess) {
    //在本地缓存设置得到的账户信息
    [UMSocialAccountManager
 setSnsAccount:sinaAccount];
    //进入你自定义的分享内容编辑页面或者使用我们的内容编辑页面
   }}];
 
  }
  else
  {
   [_WeiboSwitch
 setOn:NO animated:YES];
  }
  });
 }
 }
}
 
+(void)deleteSelectedImage:(NSInteger)index
{
 if(currentImages!=nil)
 [currentImages
 removeObjectAtIndex:index];
}
+(void)deleteSelectedImageWithImage:(UIImage
 *)image{
 if(currentImages!=nil)
 [currentImages
 removeObject:image];
 
}
@end 

 预览界面:

//
// YSYPreviewViewController.h
// NineShare
//
// Created by ZhangChangwei on 15/2/1.
// Copyright (c) 2015年 9Studio. All rights reserved.
//
 
#import 
#import "PostTableViewController.h"
 
@interface YSYPreviewViewController : UIViewController
+(void) setPreviewImage:(UIImage *)image;
@end
//
// YSYPreviewViewController.m
// NineShare
//
// Created by ZhangChangwei on 15/2/1.
// Copyright (c) 2015年 9Studio. All rights reserved.
//
 
#import "YSYPreviewViewController.h"
static UIImage *currentImage;
@interface YSYPreviewViewController ()
- (IBAction)deleteSelectedImage:(id)sender;
@property (weak, nonatomic) IBOutlet UIImageView *previewImageView;
 
@end
 
@implementation YSYPreviewViewController
 
- (void)viewDidLoad {
 [super viewDidLoad];
 // Do any additional setup after loading the view.
 _previewImageView.image=currentImage;
}
 
- (void)didReceiveMemoryWarning {
 [super didReceiveMemoryWarning];
 // Dispose of any resources that can be recreated.
}
 
/*
#pragma mark - Navigation
 
// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
 // Get the new view controller using [segue destinationViewController].
 // Pass the selected object to the new view controller.
}
*/
 
- (IBAction)deleteSelectedImage:(id)sender {
 UIActionSheet *action=[[UIActionSheet alloc] initWithTitle:@"要删除这张照片吗?" delegate:self cancelButtonTitle:@"取消" destructiveButtonTitle:@"删除" otherButtonTitles: nil];
 [action showInView:self.view];
}
-(void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex{
 if(buttOnIndex==actionSheet.cancelButtonIndex)
 {
 return;
 }
 else
 {
 [PostTableViewController deleteSelectedImageWithImage:currentImage];
 [self.navigationController popToRootViewControllerAnimated:YES];
 }
}
 
+(void)setPreviewImage:(UIImage *)image{
 currentImage=image;
}
@end

以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持。


推荐阅读
  • 本文讨论了Alink回归预测的不完善问题,指出目前主要针对Python做案例,对其他语言支持不足。同时介绍了pom.xml文件的基本结构和使用方法,以及Maven的相关知识。最后,对Alink回归预测的未来发展提出了期待。 ... [详细]
  • 本文讨论了如何优化解决hdu 1003 java题目的动态规划方法,通过分析加法规则和最大和的性质,提出了一种优化的思路。具体方法是,当从1加到n为负时,即sum(1,n)sum(n,s),可以继续加法计算。同时,还考虑了两种特殊情况:都是负数的情况和有0的情况。最后,通过使用Scanner类来获取输入数据。 ... [详细]
  • 本文介绍了九度OnlineJudge中的1002题目“Grading”的解决方法。该题目要求设计一个公平的评分过程,将每个考题分配给3个独立的专家,如果他们的评分不一致,则需要请一位裁判做出最终决定。文章详细描述了评分规则,并给出了解决该问题的程序。 ... [详细]
  • 本文介绍了C++中省略号类型和参数个数不确定函数参数的使用方法,并提供了一个范例。通过宏定义的方式,可以方便地处理不定参数的情况。文章中给出了具体的代码实现,并对代码进行了解释和说明。这对于需要处理不定参数的情况的程序员来说,是一个很有用的参考资料。 ... [详细]
  • 本文介绍了OC学习笔记中的@property和@synthesize,包括属性的定义和合成的使用方法。通过示例代码详细讲解了@property和@synthesize的作用和用法。 ... [详细]
  • 本文主要解析了Open judge C16H问题中涉及到的Magical Balls的快速幂和逆元算法,并给出了问题的解析和解决方法。详细介绍了问题的背景和规则,并给出了相应的算法解析和实现步骤。通过本文的解析,读者可以更好地理解和解决Open judge C16H问题中的Magical Balls部分。 ... [详细]
  • Mac OS 升级到11.2.2 Eclipse打不开了,报错Failed to create the Java Virtual Machine
    本文介绍了在Mac OS升级到11.2.2版本后,使用Eclipse打开时出现报错Failed to create the Java Virtual Machine的问题,并提供了解决方法。 ... [详细]
  • 本文讨论了使用差分约束系统求解House Man跳跃问题的思路与方法。给定一组不同高度,要求从最低点跳跃到最高点,每次跳跃的距离不超过D,并且不能改变给定的顺序。通过建立差分约束系统,将问题转化为图的建立和查询距离的问题。文章详细介绍了建立约束条件的方法,并使用SPFA算法判环并输出结果。同时还讨论了建边方向和跳跃顺序的关系。 ... [详细]
  • 本文介绍了在Win10上安装WinPythonHadoop的详细步骤,包括安装Python环境、安装JDK8、安装pyspark、安装Hadoop和Spark、设置环境变量、下载winutils.exe等。同时提醒注意Hadoop版本与pyspark版本的一致性,并建议重启电脑以确保安装成功。 ... [详细]
  • 本文介绍了MyBioSource转甲状腺素蛋白定量检测ELISA试剂盒的应用方法及特点。ELISA法作为一项新技术在免疫诊断中的应用范围不断扩大,不仅适用于多种病原微生物引起的传染病、非传染病的免疫诊断,也可用于大/小分子抗原的定量检测。ELISA法具有灵敏、特异、简单、快速、稳定及易于自动化操作等特点,是一种早期诊断的良好方法,也可用于血清流行病学调查。MyBioSource转甲状腺素蛋白定量检测ELISA试剂盒使用方法包括对血清和血浆的操作要求。 ... [详细]
  • Android Studio Bumblebee | 2021.1.1(大黄蜂版本使用介绍)
    本文介绍了Android Studio Bumblebee | 2021.1.1(大黄蜂版本)的使用方法和相关知识,包括Gradle的介绍、设备管理器的配置、无线调试、新版本问题等内容。同时还提供了更新版本的下载地址和启动页面截图。 ... [详细]
  • 本文介绍了一种划分和计数油田地块的方法。根据给定的条件,通过遍历和DFS算法,将符合条件的地块标记为不符合条件的地块,并进行计数。同时,还介绍了如何判断点是否在给定范围内的方法。 ... [详细]
  • 本文讲述了作者通过点火测试男友的性格和承受能力,以考验婚姻问题。作者故意不安慰男友并再次点火,观察他的反应。这个行为是善意的玩人,旨在了解男友的性格和避免婚姻问题。 ... [详细]
  • 安卓select模态框样式改变_微软Office风格的多端(Web、安卓、iOS)组件库——Fabric UI...
    介绍FabricUI是微软开源的一套Office风格的多端组件库,共有三套针对性的组件,分别适用于web、android以及iOS,Fab ... [详细]
  • 本文介绍了多因子选股模型在实际中的构建步骤,包括风险源分析、因子筛选和体系构建,并进行了模拟实证回测。在风险源分析中,从宏观、行业、公司和特殊因素四个角度分析了影响资产价格的因素。具体包括宏观经济运行和宏经济政策对证券市场的影响,以及行业类型、行业生命周期和行业政策对股票价格的影响。 ... [详细]
author-avatar
无为南子_274
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有